8000 Updated github workflows · mrpowerus/salesforce-bulk-python@807622f · GitHub
[go: up one dir, main page]

Skip to content 65E4

Commit 807622f

Browse files
committed
Updated github workflows
1 parent d1657f6 commit 807622f

File tree

2 files changed

+46
-0
lines changed

2 files changed

+46
-0
lines changed

.github/workflows/build.yml

Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
# This workflow will upload a Python Package using Twine when a release is created
2+
# For more information see: https://help.github.com/en/actions/language-and-framework-guides/using-python-with-github-actions#publishing-to-package-registries
3+
4+
# This workflow uses actions that are not certified by GitHub.
5+
# They are provided by a third-party and are governed by
6+
# separate terms of service, privacy policy, and support
7+
# documentation.
8+
9+
name: Upload Python Package
10+
11+
on: [push, pull_request]
12+
13+
jobs:
14+
test:
15+
runs-on: ubuntu-latest
16+
steps:
17+
- uses: actions/checkout@v2
18+
- name: Set up Python
19+
uses: actions/setup-python@v2
20+
with:
21+
python-version: '3.x'
22+
- name: Install dependencies
23+
run: |
24+
python -m pip install --upgrade pip
25+
pip install -r requirements.txt
26+
pip install build
27+
- name: Run tests
28+
run: |
29+
coverage run -m pytest
30+
env:
31+
SF_CONSUMER_KEY: ${{ secrets.SF_CONSUMER_KEY }}
32+
SF_PRIVATE_KEY: ${{ secrets.SF_PRIVATE_KEY }}
33+
SF_USERNAME: ${{ secrets.SF_USERNAME }}
34+
35+
36+
deploy:
37+
if: ${{ github.ref == 'refs/heads/master' }}
38+
runs-on: ubuntu-latest
39+
steps:
40+
- name: Build package
41+
run: python -m build
42+
- name: Publish package
43+
uses: pypa/gh-action-pypi-publish@27b31702a0e7fc50959f5ad993c78deac1bdfc29
44+
with:
45+
user: __token__
46+
password: ${{ secrets.PYPI_API_TOKEN }}
File renamed without changes.

0 commit comments

Comments
 (0)
0