-
Notifications
You must be signed in to change notification settings - Fork 7
63 lines (55 loc) · 1.71 KB
/
internal-release.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
name: Internal Release
on:
push:
tags-ignore:
- '*.*'
paths-ignore:
- "setup.py"
- "*.yml"
- "*.md"
- "skyflow/version.py"
branches:
- release/*
pull_request:
branches:
- release/*
jobs:
build-and-deploy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
with:
token: ${{ secrets.PAT_ACTIONS }}
ref: main
fetch-depth: 0
- uses: actions/setup-python@v2
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install setuptools wheel twine
- name: Get Previous tag
id: previoustag
uses: WyriHaximus/github-action-get-previous-tag@v1
with:
fallback: 1.0.0
- name: Bump Version
run: |
chmod +x ./ci-scripts/bump_version.sh
./ci-scripts/bump_version.sh "${{ steps.previoustag.outputs.tag }}" "$(git rev-parse --short "$GITHUB_SHA")"
- name: Commit changes
run: |
git config user.name ${{ github.actor }}
git config user.email ${{ github.actor }}@users.noreply.github.com
git add setup.py
git add skyflow/version.py
git commit -m "[AUTOMATED] Public Release - ${{ steps.previoustag.outputs.tag }}"
git push origin
- name: Build the package
run: |
python setup.py sdist bdist_wheel
# - name: Publish to JFrog Artifactory
# env:
# TWINE_USERNAME: ${{ secrets.JFROG_USERNAME }}
# TWINE_PASSWORD: ${{ secrets.JFROG_PASSWORD }}
# run: |
# twine upload --repository-url https://prekarilabs.jfrog.io/prekarilabs/api/pypi/skyflow-python/ dist/*