Skip to content

Commit f699d3d

Browse files
committed
fix: formatting, use exercise test yml
1 parent f8eea3d commit f699d3d

File tree

5 files changed

+36
-21
lines changed

5 files changed

+36
-21
lines changed

.github/workflows/package-matrix.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
11
name: Package — Build & Upload using Matrix
2+
env:
3+
PIP_DISABLE_PIP_VERSION_CHECK: "1"
24

35
on:
46
workflow_dispatch:

.github/workflows/package.yml

Lines changed: 25 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -3,25 +3,30 @@ name: Simple Package — Sequential macOS arm64 & Windows x64
33
on:
44
workflow_dispatch: # manual trigger
55
push:
6-
tags: ['v*']
6+
tags: ["v*"]
77

88
jobs:
99
build-macos-arm64:
1010
name: Build macOS arm64
11-
runs-on: macos-14
11+
runs-on: macos-latest
1212
steps:
1313
- name: Check out
1414
uses: actions/checkout@v4
15+
1516
- name: Show runner arch
1617
run: uname -m || true
1718
- name: Setup Python
1819
uses: actions/setup-python@v4
1920
with:
20-
python-version: '3.11'
21+
python-version: "3.11"
22+
23+
# Exercise 1: Implement dependency installation here
2124
- name: Install deps
2225
run: |
2326
python -m pip install --upgrade pip
24-
pip install -r requirements.txt
27+
echo "TODO: Achieve pip requirements installation over here"
28+
29+
# Remember to add a -n parameter to name the output binary appropriately for each platform
2530
- name: Build with PyInstaller (macOS arm64)
2631
run: |
2732
pyinstaller --onefile app/hello.py -n hello-macos-arm64
@@ -42,20 +47,26 @@ jobs:
4247
- name: Setup Python
4348
uses: actions/setup-python@v4
4449
with:
45-
python-version: '3.11'
50+
python-version: "3.11"
51+
4652
- name: Install deps
4753
run: |
4854
python -m pip install --upgrade pip
4955
pip install -r requirements.txt
50-
- name: Build with PyInstaller (Windows x64)
51-
shell: pwsh
52-
run: |
53-
pyinstaller --onefile app/hello.py -n hello-windows-x64
56+
57+
# Exercise 2: Implement Windows build steps here
58+
# You can refer to the macOS build steps above for guidance
59+
# - name: Build with PyInstaller (Windows x64)
60+
# ...
61+
5462
- name: Debug dist
5563
shell: pwsh
5664
run: dir dist || true
57-
- name: Upload Windows artifact
58-
uses: actions/upload-artifact@v4
59-
with:
60-
name: hello-windows-x64
61-
path: dist/hello-windows-x64.exe
65+
66+
# Exercise 3: Implement artifact upload here
67+
# - name: Upload Windows artifact
68+
# uses: actions/upload-artifact@v4
69+
# with:
70+
# name: hello-windows-x64
71+
# path: # TODO: Specify the path to the Windows build artifact here.
72+
# it is a file with .exe extension named by you under `dist/`, generated in Exercise 2

solutions/package-exercise.yml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@ jobs:
1212
steps:
1313
- name: Check out
1414
uses: actions/checkout@v4
15-
1615
- name: Show runner arch
1716
run: uname -m || true
1817
- name: Setup Python
@@ -48,12 +47,12 @@ jobs:
4847
uses: actions/setup-python@v4
4948
with:
5049
python-version: "3.11"
51-
50+
5251
- name: Install deps
5352
run: |
5453
python -m pip install --upgrade pip
5554
pip install -r requirements.txt
56-
55+
5756
# Exercise 2: Implement Windows build steps here
5857
# You can refer to the macOS build steps above for guidance
5958
# - name: Build with PyInstaller (Windows x64)

solutions/package-matrix.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
11
name: Package — Build & Upload using Matrix
2+
env:
3+
PIP_DISABLE_PIP_VERSION_CHECK: "1"
24

35
on:
46
workflow_dispatch:

solutions/package.yml

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,12 +3,12 @@ name: Simple Package — Sequential macOS arm64 & Windows x64
33
on:
44
workflow_dispatch: # manual trigger
55
push:
6-
tags: ['v*']
6+
tags: ["v*"]
77

88
jobs:
99
build-macos-arm64:
1010
name: Build macOS arm64
11-
runs-on: macos-14
11+
runs-on: macos-latest
1212
steps:
1313
- name: Check out
1414
uses: actions/checkout@v4
@@ -17,7 +17,8 @@ jobs:
1717
- name: Setup Python
1818
uses: actions/setup-python@v4
1919
with:
20-
python-version: '3.11'
20+
python-version: "3.11"
21+
2122
- name: Install deps
2223
run: |
2324
python -m pip install --upgrade pip
@@ -42,7 +43,7 @@ jobs:
4243
- name: Setup Python
4344
uses: actions/setup-python@v4
4445
with:
45-
python-version: '3.11'
46+
python-version: "3.11"
4647
- name: Install deps
4748
run: |
4849
python -m pip install --upgrade pip

0 commit comments

Comments
 (0)