Skip to content

Commit 50c2faa

Browse files
committed
chore: update GitHub workflows for packaging with Cythinst64; enhance artifact handling and permissions
(cherry picked from commit c6f2db8)
1 parent 5788937 commit 50c2faa

2 files changed

Lines changed: 63 additions & 61 deletions

File tree

.github/workflows/pinstaltkinter.yaml

Lines changed: 20 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -4,38 +4,39 @@ on:
44
push:
55
tags:
66
- 'tkinter_v*' # Push events with a tag that starts with 'tkinter_v'
7+
workflow_dispatch:
8+
9+
permissions:
10+
contents: write
711

812
jobs:
913
build:
1014
runs-on: ubuntu-latest
1115
steps:
12-
- uses: actions/checkout@v4
16+
- uses: actions/checkout@v6.0.2
1317

14-
- name: Package Application
15-
uses: JackMcKew/pyinstaller-action-windows@main
18+
- name: Package Application using Cythinst64
19+
uses: PlohnenSoftware/Cythinst64@dev
1620
with:
1721
path: src
22+
zip_name: familiada.zip
23+
zip_paths: |
24+
src/dist/windows
25+
dane.csv
1826
19-
# Step to create a flat directory for carrying output files
20-
- name: Create output directory
21-
run: mkdir familiada_all
22-
23-
# Step to move compiled Windows binaries
24-
- name: Move Windows binaries
25-
run: mv src/dist/windows/* familiada_all/
26-
27-
# Step to move data file
28-
- name: Move data file
29-
run: mv dane.csv familiada_all/
30-
31-
# Step to zip the flat folder
32-
- name: Zip output folder
33-
run: zip -r familiada.zip familiada_all
27+
# Step to upload the zipped folder as a workflow artifact
28+
- name: Upload artifact
29+
uses: actions/upload-artifact@v7.0.1
30+
with:
31+
name: familiada-tkinter
32+
path: familiada.zip
33+
if-no-files-found: error
3434

3535
# Step to create a release and upload the zipped folder as an asset
3636
- name: Create Release
37+
if: startsWith(github.ref, 'refs/tags/tkinter_v')
3738
id: create_release
38-
uses: softprops/action-gh-release@v1
39+
uses: softprops/action-gh-release@v3.0.0
3940
with:
4041
files: familiada.zip
4142
env:

.github/workflows/pyinstaller.yml

Lines changed: 43 additions & 42 deletions
Original file line numberDiff line numberDiff line change
@@ -1,42 +1,43 @@
1-
name: Package Familiada App with Pyinstaller
2-
3-
on:
4-
push:
5-
tags:
6-
- 'v*' # Push events to matching v*, i.e. v1.0, v20.15.10
7-
8-
jobs:
9-
build:
10-
runs-on: ubuntu-latest
11-
steps:
12-
- uses: actions/checkout@v4
13-
- name: Package Application using Cythinst64
14-
uses: PlohnenSoftware/Cythinst64@v1.2
15-
with:
16-
path: src
17-
cython_out: prec
18-
19-
# Step to create a flat directory for carrying output files
20-
- name: Create output directory
21-
run: mkdir familiada
22-
23-
# Step to move compiled Windows binaries
24-
- name: Move Windows binaries
25-
run: mv src/dist/windows/* familiada/
26-
27-
# Step to move data file
28-
- name: Move data file
29-
run: mv dane.csv familiada/
30-
31-
# Step to zip the flat folder
32-
- name: Zip output folder
33-
run: zip -r familiada.zip familiada
34-
35-
# Step to create a release and upload the zipped folder as an asset
36-
- name: Create Release
37-
id: create_release
38-
uses: softprops/action-gh-release@v1
39-
with:
40-
files: familiada.zip
41-
env:
42-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
1+
name: Package Familiada App with Pyinstaller
2+
3+
on:
4+
push:
5+
tags:
6+
- 'v*' # Push events to matching v*, i.e. v1.0, v20.15.10
7+
workflow_dispatch:
8+
9+
permissions:
10+
contents: write
11+
12+
jobs:
13+
build:
14+
runs-on: ubuntu-latest
15+
steps:
16+
- uses: actions/checkout@v6.0.2
17+
- name: Package Application using Cythinst64
18+
uses: PlohnenSoftware/Cythinst64@dev
19+
with:
20+
path: src
21+
cython_out: prec
22+
zip_name: familiada.zip
23+
zip_paths: |
24+
src/dist/windows
25+
dane.csv
26+
27+
# Step to upload the zipped folder as a workflow artifact
28+
- name: Upload artifact
29+
uses: actions/upload-artifact@v7.0.1
30+
with:
31+
name: familiada
32+
path: familiada.zip
33+
if-no-files-found: error
34+
35+
# Step to create a release and upload the zipped folder as an asset
36+
- name: Create Release
37+
if: startsWith(github.ref, 'refs/tags/v')
38+
id: create_release
39+
uses: softprops/action-gh-release@v3.0.0
40+
with:
41+
files: familiada.zip
42+
env:
43+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

0 commit comments

Comments
 (0)