-
Notifications
You must be signed in to change notification settings - Fork 0
Fix broken desktop download links and add automated release workflow #8
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||
|---|---|---|---|---|---|---|
| @@ -0,0 +1,106 @@ | ||||||
| name: Build and Release Desktop Apps | ||||||
|
|
||||||
| on: | ||||||
| push: | ||||||
| tags: | ||||||
| - 'v*.*.*' # Trigger on version tags like v2.1.0 | ||||||
| workflow_dispatch: # Allow manual triggering | ||||||
|
|
||||||
| permissions: | ||||||
| contents: write # Required to create GitHub Releases | ||||||
|
|
||||||
| jobs: | ||||||
| build-desktop: | ||||||
| strategy: | ||||||
| fail-fast: false | ||||||
| matrix: | ||||||
| os: [ubuntu-latest, windows-latest, macos-latest] | ||||||
| include: | ||||||
| - os: ubuntu-latest | ||||||
| platform: linux | ||||||
| artifact: ODIA-*.AppImage | ||||||
| - os: windows-latest | ||||||
| platform: windows | ||||||
| artifact: ODIA-Setup-*.exe | ||||||
| - os: macos-latest | ||||||
| platform: mac | ||||||
| artifact: ODIA-*.dmg | ||||||
|
|
||||||
| runs-on: ${{ matrix.os }} | ||||||
|
|
||||||
| steps: | ||||||
| - name: Checkout code | ||||||
| uses: actions/checkout@v4 | ||||||
|
|
||||||
| - name: Setup Node.js | ||||||
| uses: actions/setup-node@v4 | ||||||
| with: | ||||||
| node-version: '20' | ||||||
| cache: 'npm' | ||||||
| cache-dependency-path: desktop/package-lock.json | ||||||
|
|
||||||
| - name: Setup Python | ||||||
| uses: actions/setup-python@v5 | ||||||
| with: | ||||||
| python-version: '3.11' | ||||||
| cache: 'pip' | ||||||
|
|
||||||
| - name: Install system dependencies (Linux) | ||||||
| if: matrix.os == 'ubuntu-latest' | ||||||
| run: | | ||||||
| sudo apt-get update | ||||||
| sudo apt-get install -y build-essential fakeroot rpm libfuse2 | ||||||
|
|
||||||
| - name: Install Python dependencies | ||||||
| run: | | ||||||
| python -m pip install --upgrade pip | ||||||
| pip install -e ".[dev]" | ||||||
| pip install pyinstaller | ||||||
|
|
||||||
| - name: Build Python backend | ||||||
| working-directory: desktop | ||||||
| run: | | ||||||
| npm ci | ||||||
| npm run build:backend | ||||||
|
|
||||||
| - name: Build frontend for Electron | ||||||
| working-directory: frontend | ||||||
| shell: bash | ||||||
| env: | ||||||
| ELECTRON_BUILD: '1' | ||||||
| run: | | ||||||
| npm ci | ||||||
|
||||||
| npm ci | |
| npm install |
| Original file line number | Diff line number | Diff line change | ||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
|
@@ -17,16 +17,21 @@ Legistar-based jurisdiction or custom legal corpus. | |||||||||||
|
|
||||||||||||
| **Desktop App (no installation prerequisites):** | ||||||||||||
|
|
||||||||||||
| Download the standalone desktop application — no Python, Docker, or command line | ||||||||||||
| required. All analysis runs locally on your machine. | ||||||||||||
| Pre-built installers will be available in the [Releases](https://github.com/SynTechRev/ODIA/releases) section soon. For now, build the desktop application locally: | ||||||||||||
|
|
||||||||||||
|
Comment on lines
18
to
21
|
||||||||||||
| | Platform | Download | | ||||||||||||
| |----------|----------| | ||||||||||||
| | Windows | [ODIA-Setup.exe](https://github.com/SynTechRev/ODIA/releases/latest/download/ODIA-Setup.exe) | | ||||||||||||
| | macOS | [ODIA.dmg](https://github.com/SynTechRev/ODIA/releases/latest/download/ODIA.dmg) | | ||||||||||||
| | Linux | [ODIA.AppImage](https://github.com/SynTechRev/ODIA/releases/latest/download/ODIA.AppImage) | | ||||||||||||
| ```bash | ||||||||||||
| # Build desktop application | ||||||||||||
| cd desktop | ||||||||||||
| npm install | ||||||||||||
|
||||||||||||
| npm install | |
| npm install | |
| cd .. | |
| pip install -e .[desktop] # Install Python package deps and PyInstaller | |
| cd desktop |
Copilot
AI
Apr 12, 2026
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
npm ci will fail in frontend/ because the repo doesn’t include a frontend/package-lock.json (or other lockfile). Either add a lockfile and keep npm ci, or switch these instructions to npm install to match the current repo state.
| npm ci | |
| npm install |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,78 @@ | ||
| # Release Process | ||
|
|
||
| ## Automated Desktop Releases | ||
|
|
||
| Desktop application releases are automated via GitHub Actions | ||
| (`.github/workflows/release-desktop.yml`). | ||
|
|
||
| ### Creating a New Release | ||
|
|
||
| 1. **Update version** in relevant package files: | ||
|
|
||
| ```bash | ||
| # Update desktop/package.json version field to X.Y.Z | ||
| # Update pyproject.toml version field to X.Y.Z | ||
| ``` | ||
|
|
||
| 2. **Commit version bump:** | ||
|
|
||
| ```bash | ||
| git add desktop/package.json pyproject.toml | ||
| git commit -m "chore: bump version to X.Y.Z" | ||
| git push | ||
| ``` | ||
|
|
||
| 3. **Create and push tag:** | ||
|
|
||
| ```bash | ||
| git tag vX.Y.Z | ||
| git push origin vX.Y.Z | ||
| ``` | ||
|
|
||
| 4. **GitHub Actions automatically:** | ||
| - Builds desktop installers for Windows, macOS, and Linux | ||
| - Creates a GitHub Release | ||
| - Uploads installers as release assets | ||
| - Generates release notes | ||
|
|
||
| 5. **Verify release:** | ||
| - Check <https://github.com/SynTechRev/ODIA/releases> | ||
| - Test download links work | ||
| - Download and test installers on each platform | ||
|
|
||
| ### Manual Release (Fallback) | ||
|
|
||
| If the automated release fails: | ||
|
|
||
| ```bash | ||
| # Build locally for your platform | ||
| cd desktop | ||
| npm run build:win # Windows | ||
| npm run build:mac # macOS | ||
| npm run build:linux # Linux | ||
|
|
||
| # Manually create a release on GitHub and upload installers from desktop/dist/ | ||
| ``` | ||
|
Comment on lines
+47
to
+55
|
||
|
|
||
| ## Release Checklist | ||
|
|
||
| - [ ] Version bumped in `desktop/package.json` | ||
| - [ ] Version bumped in `pyproject.toml` | ||
| - [ ] CHANGELOG updated (if maintained) | ||
| - [ ] All tests passing (`pytest` and `cd desktop && npm test`) | ||
| - [ ] Desktop app builds successfully locally | ||
| - [ ] Tag created and pushed (`git tag vX.Y.Z && git push origin vX.Y.Z`) | ||
| - [ ] GitHub Actions workflow completes without errors | ||
| - [ ] Release appears on <https://github.com/SynTechRev/ODIA/releases> | ||
| - [ ] Download links tested | ||
| - [ ] Installers tested on target platforms (Windows, macOS, Linux) | ||
|
|
||
| ## Workflow Overview | ||
|
|
||
| The release workflow (`.github/workflows/release-desktop.yml`) runs on: | ||
|
|
||
| - **Version tags** matching `v*.*.*` (e.g., `v2.1.0`) — full build + release | ||
| - **Manual dispatch** — full build + artifact upload (no release created unless on a tag) | ||
|
|
||
| The existing CI workflow (`.github/workflows/desktop-build.yml`) handles | ||
| continuous integration builds for pull requests and branch pushes. | ||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The Windows artifact glob
ODIA-Setup-*.exeis more specific than the existing CI workflow (which uploadsdesktop/dist/*.exe) and may not match electron-builder’s default NSIS naming (often includes spaces). Consider usingdesktop/dist/*.exe(and similar broad globs) or explicitly settingartifactNamein the electron-builder config to guarantee these names.