Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
92 changes: 92 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,92 @@
name: Build

on:
push:
branches: ["main"]
pull_request:
workflow_dispatch:

# No job here creates releases, publishes packages, or writes via the API.
permissions:
contents: read

jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
Comment thread
coderabbitai[bot] marked this conversation as resolved.
with:
persist-credentials: false
- uses: actions/setup-python@v5
Comment on lines +17 to +20

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 security Mutable CI action references

The workflow resolves checkout, setup-python, and upload-artifact through mutable major-version tags, so repointing an upstream tag changes the code executed for the same repository commit and can affect the unsigned macOS artifacts published by this workflow. Pin each action to a full commit SHA to make CI execution and distributed artifacts reproducible.

How this was verified: The artifact-producing job uses mutable action tags before building and uploading the downloadable application bundles.

Note: If this suggestion doesn't match your team's coding style, reply to this and let me know. I'll remember it for next time!

Fix in Claude Code

with:
python-version: "3.12"
cache: pip
# The engine has no UI imports, so it tests without a display.
- run: pip install Pillow piexif
- run: python tests/test_engine.py

smoke:
needs: test
strategy:
fail-fast: false
matrix:
os: [macos-14, windows-latest]
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v4
with:
persist-credentials: false
- uses: actions/setup-python@v5
with:
python-version: "3.12"
cache: pip
- run: pip install -r requirements.txt
# Proves the GUI actually constructs on this OS — imports, fonts, theme
# tokens, widget options — rather than only that the engine passes.
- run: python main.py --check
- run: python tests/test_gui_boot.py

macos-app:
needs: smoke
strategy:
fail-fast: false
matrix:
include:
# py2app bundles the running interpreter, so a single runner produces
# a single-arch app that will not launch on the other kind of Mac.
# macos-15-intel is the current Intel label; macos-13 was retired and
# a job targeting it queues forever instead of failing.
- runner: macos-15-intel
arch: intel
- runner: macos-14
arch: apple-silicon
runs-on: ${{ matrix.runner }}
steps:
- uses: actions/checkout@v4
with:
persist-credentials: false
- uses: actions/setup-python@v5
with:
python-version: "3.12"
cache: pip
- run: |
pip install -r requirements.txt
pip install py2app
# v1's workflow cd'd into a folder that was never in the repo, so this
# job had never once produced a bundle.
- run: python setup.py py2app
- name: Verify the bundle launches
run: |
APP="dist/WebP Studio.app"
test -d "$APP" || { echo "no bundle produced"; exit 1; }
file "$APP/Contents/MacOS/WebP Studio"
# Headless runners have no window server, so a full launch can't be
# tested here — confirm the embedded interpreter starts and imports.
"$APP/Contents/MacOS/WebP Studio" --check
- run: ditto -c -k --keepParent "dist/WebP Studio.app" "WebP-Studio-macOS-${{ matrix.arch }}.zip"
- uses: actions/upload-artifact@v4
with:
name: WebP-Studio-macOS-${{ matrix.arch }}
path: WebP-Studio-macOS-${{ matrix.arch }}.zip
retention-days: 14

43 changes: 0 additions & 43 deletions .github/workflows/build_mac_app.yml

This file was deleted.

36 changes: 1 addition & 35 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,42 +1,8 @@
# Python
__pycache__/
*.py[cod]
*$py.class
*.so
.Python
build/
develop-eggs/
dist/
downloads/
eggs/
.eggs/
lib/
lib64/
parts/
sdist/
var/
wheels/
share/python-wheels/
*.egg-info/
.installed.cfg
*.egg
MANIFEST

# Virtual Environment
venv/
env/
ENV/
.env

# PyInstaller/py2app
*.spec
.app/
build/
dist/

# MacOS
.venv/
.DS_Store

# IDEs
.vscode/
.idea/
21 changes: 21 additions & 0 deletions LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
MIT License

Copyright (c) 2026 DhakadG

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
Loading
Loading