Skip to content

Commit dcbccf9

Browse files
author
Anton Benkevich
committed
Act on releases
1 parent 837e896 commit dcbccf9

File tree

3 files changed

+46
-24
lines changed

3 files changed

+46
-24
lines changed

.github/workflows/stage3_release_artefacts.yml renamed to .github/workflows/stage3_release_pypi.yml

Lines changed: 4 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,14 @@
11
# This workflow will install Python dependencies, run tests and lint with a variety of Python versions
22
# For more information see: https://help.github.com/actions/language-and-framework-guides/using-python-with-github-actions
33

4-
name: Test and release to PyPi and GitHub
5-
4+
name: Test and release to PyPi
65
on:
76
push:
87
tags:
98
- 'v[0-9]+.[0-9]+.[0-9]+'
9+
release:
10+
types:
11+
- created
1012

1113
jobs:
1214
test:
@@ -49,25 +51,3 @@ jobs:
4951
run: |
5052
python setup.py sdist bdist_wheel
5153
twine upload --skip-existing dist/*
52-
- name: Build GH release assets
53-
run: |
54-
cd alsdkdefs/apis; zip -r ../../AlertLogicOpenAPIDefinitions.zip .; cd ../..
55-
- name: Create GH Release
56-
id: create_release
57-
uses: actions/create-release@v1
58-
env:
59-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
60-
with:
61-
tag_name: ${{ github.ref }}
62-
draft: false
63-
prerelease: false
64-
- name: Upload Release Asset
65-
id: upload-release-asset
66-
uses: actions/upload-release-asset@v1
67-
env:
68-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
69-
with:
70-
upload_url: ${{ steps.create_release.outputs.upload_url }}
71-
asset_path: ./AlertLogicOpenAPIDefinitions.zip
72-
asset_name: AlertLogicOpenAPIDefinitions.zip
73-
asset_content_type: application/zip
Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
# This workflow will install Python dependencies, run tests and lint with a variety of Python versions
2+
# For more information see: https://help.github.com/actions/language-and-framework-guides/using-python-with-github-actions
3+
4+
name: Add gh release
5+
on:
6+
push:
7+
tags:
8+
- 'v[0-9]+.[0-9]+.[0-9]+'
9+
10+
jobs:
11+
deploy:
12+
runs-on: ubuntu-latest
13+
steps:
14+
- uses: actions/checkout@v2
15+
# - name: Create GH Release
16+
# id: create_release
17+
# uses: actions/create-release@v1
18+
# env:
19+
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
20+
# with:
21+
# tag_name: ${{ github.ref }}
22+
# draft: false
23+
# prerelease: false
24+
- name: Build GH release assets
25+
run: |
26+
cd alsdkdefs/apis; zip -r ../../AlertLogicOpenAPIDefinitions.zip .; cd ../..
27+
- name: Update release
28+
uses: johnwbyrd/[email protected]
29+
with:
30+
tag: ${{ github.ref }}
31+
token: ${{ secrets.GITHUB_TOKEN }}
32+
files: ./AlertLogicOpenAPIDefinitions.zip
33+
# - name: Upload Release Asset
34+
# id: upload-release-asset
35+
# uses: actions/upload-release-asset@v1
36+
# env:
37+
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
38+
# with:
39+
# upload_url: ${{ steps.create_release.outputs.upload_url }}
40+
# asset_path: ./AlertLogicOpenAPIDefinitions.zip
41+
# asset_name: AlertLogicOpenAPIDefinitions.zip
42+
# asset_content_type: application/zip

0 commit comments

Comments
 (0)