Skip to content

Commit cfb86a9

Browse files
committed
Initial commit: Source code, build scripts, and docs (AudioShelf V1.0)
0 parents  commit cfb86a9

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

89 files changed

+13088
-0
lines changed

.github/workflows/build.yml

Lines changed: 97 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,97 @@
1+
name: Build and Release AudioShelf
2+
3+
on:
4+
push:
5+
tags:
6+
- 'v*'
7+
8+
permissions:
9+
contents: write
10+
11+
jobs:
12+
build:
13+
name: Build Windows App
14+
runs-on: windows-latest
15+
16+
steps:
17+
- name: Checkout code
18+
uses: actions/checkout@v4
19+
20+
- name: Setup Python
21+
uses: actions/setup-python@v5
22+
with:
23+
python-version: '3.14'
24+
cache: 'pip'
25+
26+
- name: Install Dependencies
27+
run: |
28+
python -m pip install --upgrade pip
29+
pip install -r requirements.txt
30+
pip install pyinstaller
31+
32+
- name: Read Version from File
33+
id: get_version
34+
shell: powershell
35+
run: |
36+
$ver = Get-Content VERSION
37+
echo "VERSION=$ver" >> $env:GITHUB_ENV
38+
Write-Host "Detected Version: $ver"
39+
40+
- name: Update Changelog and Push
41+
run: |
42+
python update_changelog.py $env:VERSION
43+
44+
git config --global user.name "GitHub Action"
45+
git config --global user.email "[email protected]"
46+
47+
git add CHANGELOG.md
48+
git commit -m "Auto-update Changelog for version $env:VERSION [skip ci]" || Write-Host "No changes to commit"
49+
git push
50+
51+
- name: Generate Version Info for Exe
52+
run: |
53+
python create_version.py $env:VERSION
54+
55+
- name: Build with PyInstaller
56+
run: |
57+
python -m PyInstaller AudioShelf.spec
58+
59+
- name: Create Portable Zip
60+
run: |
61+
$ZIP_NAME = "AudioShelf-$env:VERSION-Win64-Portable.zip"
62+
63+
New-Item -ItemType Directory -Force -Path "PortableStaging\AudioShelf"
64+
Copy-Item -Path "dist\AudioShelf\*" -Destination "PortableStaging\AudioShelf" -Recurse
65+
New-Item -Path "PortableStaging\AudioShelf\_libs\.portable" -ItemType File
66+
67+
Compress-Archive -Path "PortableStaging\AudioShelf" -DestinationPath "$ZIP_NAME"
68+
69+
echo "PORTABLE_ZIP_NAME=$ZIP_NAME" >> $env:GITHUB_ENV
70+
71+
- name: Setup NSIS
72+
run: choco install nsis
73+
74+
- name: Build Installer
75+
run: |
76+
& "C:\Program Files (x86)\NSIS\makensis.exe" setup.nsi
77+
78+
$SETUP_NAME = "AudioShelf-$env:VERSION-Win64-Setup.exe"
79+
80+
if (Test-Path $SETUP_NAME) {
81+
Write-Host "Installer created: $SETUP_NAME"
82+
echo "SETUP_EXE_NAME=$SETUP_NAME" >> $env:GITHUB_ENV
83+
} else {
84+
Write-Error "Installer file not found!"
85+
exit 1
86+
}
87+
88+
- name: Create GitHub Release
89+
uses: softprops/action-gh-release@v1
90+
if: startsWith(github.ref, 'refs/tags/')
91+
with:
92+
files: |
93+
${{ env.PORTABLE_ZIP_NAME }}
94+
${{ env.SETUP_EXE_NAME }}
95+
body_path: CHANGELOG.md
96+
env:
97+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

.gitignore

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
# Python
2+
__pycache__/
3+
*.py[cod]
4+
venv/
5+
venv314/
6+
.env
7+
8+
# Build Artifacts
9+
build/
10+
dist/
11+
12+
13+
# User Data & Logs (Private)
14+
user_data/
15+
*.log
16+
audioshelf.db
17+
.portable
18+
19+
# IDEs
20+
.idea/
21+
.vscode/
22+
23+
# Temporary Updates
24+
audioshelf_updater.bat
25+
version_info.txt

AudioShelf.ico

132 KB
Binary file not shown.

AudioShelf.png

756 KB
Loading

0 commit comments

Comments
 (0)