File tree Expand file tree Collapse file tree 4 files changed +32
-10
lines changed Expand file tree Collapse file tree 4 files changed +32
-10
lines changed Original file line number Diff line number Diff line change @@ -2,6 +2,9 @@ name: Build binary
22
33on :
44 workflow_dispatch :
5+ push :
6+ tags :
7+ - ' *'
58
69jobs :
710 deploy :
@@ -20,21 +23,32 @@ jobs:
2023 python-version : ' 3.x'
2124
2225 - name : Install dependencies
26+ shell : bash
2327 run : |
2428 python -m pip install --upgrade pip
2529 pip install -r requirements/requirements.txt
2630 pip install -r requirements/requirements_dev.txt
2731 pip install pyinstaller
2832
2933 - name : Build binary
34+ shell : bash
3035 run : |
3136 invoke build-binary
3237
3338 - name : Test the binary
34- run :
39+ shell : bash
40+ run : |
3541 invoke test-binary
3642
3743 - name : Prepare binary for upload
38- run :
44+ shell : bash
45+ run : |
3946 invoke prepare-binary
47+
48+ - name : Upload release binaries
49+ 50+ env :
51+ GITHUB_TOKEN : ${{ github.token }}
52+ with :
53+ asset_paths : ' ["./dist/*"]'
4054
Original file line number Diff line number Diff line change 1+ 0.11.1 (2021-02-13)
2+ -------------------
3+
4+ * Release for testing publishing of self-contained binaries built via pyinstaller
5+
160.11.0 (2021-01-18)
27-------------------
38
Original file line number Diff line number Diff line change 1- __version__ = "0.11.0 "
1+ __version__ = "0.11.1 "
22__description__ = "aws-gate - AWS SSM Session Manager client CLI"
33__author__ = "Adam Stevko"
44__author_email__ = "[email protected] "
Original file line number Diff line number Diff line change @@ -12,17 +12,20 @@ def build_binary(ctx):
1212
1313@task
1414def test_binary (ctx ):
15- ctx .run ("./ dist/ aws-gate --version" )
16- ctx .run ("./ dist/ aws-gate --help" )
15+ ctx .run (f" { os . path . join ( ' dist' , ' aws-gate' ) } --version" )
16+ ctx .run (f" { os . path . join ( ' dist' , ' aws-gate' ) } --help" )
1717
1818
1919@task
2020def prepare_binary (ctx ): # pylint: disable=unused-argument
21- binary_name = "aws-gate"
22- binary_path = f"./dist/{ binary_name } "
23- platform_suffix = f"{ platform .system ()} _{ platform .machine ()} "
24- platform_binary_name = f"{ binary_name } -{ platform_suffix } "
25- platform_binary_path = f"{ binary_path } -{ platform_suffix } "
21+ if platform .system () == "Windows" :
22+ binary_name = "aws-gate.exe"
23+ else :
24+ binary_name = "aws-gate"
25+ binary_path = f"{ os .path .join ('dist' , binary_name )} "
26+ platform_suffix = f"{ platform .system ()} _{ platform .machine ().lower ()} "
27+ platform_binary_name = f"{ binary_name } _{ platform_suffix } "
28+ platform_binary_path = f"{ binary_path } _{ platform_suffix } "
2629
2730 os .rename (binary_path , platform_binary_path )
2831
You can’t perform that action at this time.
0 commit comments