-
Notifications
You must be signed in to change notification settings - Fork 0
66 lines (56 loc) · 2.05 KB
/
test_workflow.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
63
64
65
name: Test Release Package
on:
workflow_dispatch: # Allows manual triggering of the workflow
jobs:
Checkout_and_install_dependencies:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
# - name: Set up Python
# uses: actions/setup-python@v4
# with:
# python-version: '3.x'
# - name: Create virtualenv
# run: |
# python -m venv .venv
# - name: Activate virtualenv
# run: |
# source .venv/bin/activate
# echo PATH=$PATH >> $GITHUB_ENV
# - name: Install dependencies
# run: |
# python -m pip install --upgrade pip
# pip install -r requirements.txt
start_pyinstaller:
runs-on: ubuntu-latest
steps:
- name: Create Executable
uses: sayyid5416/pyinstaller@v1
with:
python_ver: '3.12.0'
pyinstaller_ver: '>=6.10.0'
spec: 'MS_Teams_Busy_Light.spec'
requirements: 'requirements.txt'
upload_exe_with_name: 'MS Teams Presence Status Busy Light'
options: --onefile --icon=$iconFile --version-file="images/traffic_light.ico" --clean --windowed"
- name: Get Release ID
id: get_release
uses: actions/github-script@v6
with:
script: |
const release = await github.repos.getReleaseByTag({
owner: context.repo.owner,
repo: context.repo.repo,
tag: 'github actions test release'
});
return release.data.id;
- name: Upload Release Asset
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.get_release.outputs.upload_url }}
asset_path: dist/MS_Teams_Busy_Light.exe # Replace with the actual path to your executable
asset_name: MS_Teams_Busy_Light.exe # Replace with the actual name of your executable
asset_content_type: application/octet-stream