Use the latest version of Rust.
On Linux, you'll need some additional system packages. Refer to the installation guide for the list.
You'll also need to install GStreamer (tested with 1.22.12). You can follow the instructions here: https://github.com/sdroege/gstreamer-rs#installation
- Run program:
cargo run
- Run tests:
cargo test
- Activate pre-commit hooks (requires Python) to handle formatting/linting:
pip install --user pre-commit pre-commit install
These are optional:
MADAMIRU_VERSION
:- If set, shown in the window title instead of the Cargo.toml version.
- Intended for CI.
The master icon is assets/icon.kra
, which you can edit using
Krita and then export into the other formats.
Commands assume you are using Git Bash on Windows.
pip install invoke
cargo install cargo-lichking
# Verified with commit ba58a5c44ccb7d2e0ca0238d833d17de17c2b53b:
curl -o /c/opt/flatpak-cargo-generator.py https://raw.githubusercontent.com/flatpak/flatpak-builder-tools/master/cargo/flatpak-cargo-generator.py
pip install aiohttp toml
Also install the Crowdin CLI tool manually.
- Update version in
CHANGELOG.md
- Update version in
Cargo.toml
- Update version in
assets/linux/com.mtkennerly.madamiru.metainfo.xml
, including thereleases
section and the screenshot URL. - Run
invoke prerelease
- If you already updated the translations separately,
then run
invoke prerelease --no-update-lang
- If you already updated the translations separately,
then run
- Update the translation percentages in src/lang.rs
- Run
cargo build
to update the version in Cargo.lock - Add the new version to
.github/ISSUE_TEMPLATE/*.yaml
. - Update the documentation if necessary for any new features.
Check for any new content that needs to be uncommented (
<!--
). - Run
git add
for all relevant changes - Run
invoke release
- This will create a new commit/tag and push them.
- Manually create a release on GitHub and attach the workflow build artifacts
(plus
dist/*-legal.zip
). For Linux and Mac, extract the.tar.gz
files from the.zip
files.
- Run
cargo publish
- Run
invoke release-flatpak
- This will automatically push a branch to https://github.com/flathub/com.mtkennerly.madamiru .
- Manually open a PR for that branch.
- After the PR is merged, publish via https://buildbot.flathub.org/#/apps/com.mtkennerly.madamiru .
- Run
invoke release-winget
-
When the script opens VSCode and pauses, manually edit
manifests/m/mtkennerly/madamiru/${VERSION}/mtkennerly.madamiru.locale.en-US.yaml
to add theReleaseNotes
andReleaseNotesUrl
fields:ReleaseNotes: |- <copy/paste from CHANGELOG.md> ReleaseNotesUrl: https://github.com/mtkennerly/madamiru/releases/tag/v${VERSION}
Close the file, and the script will continue.
-
This will automatically push a branch to a fork of https://github.com/microsoft/winget-pkgs .
-
Manually open a pull request for that branch.
-