From 5eb3261ad467235f201f209d56bb96f75a879836 Mon Sep 17 00:00:00 2001 From: Cyrille Bougot Date: Mon, 16 Mar 2026 14:27:40 +0100 Subject: [PATCH 1/5] Do not build if run from add-on template repo --- .github/workflows/build_addon.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/build_addon.yml b/.github/workflows/build_addon.yml index a392f81..9a60df1 100644 --- a/.github/workflows/build_addon.yml +++ b/.github/workflows/build_addon.yml @@ -13,6 +13,7 @@ on: jobs: build: + if: github.repository != 'nvaccess/addonTemplate' runs-on: ubuntu-latest From d4ba55fd7b550dc9a032967f11ed0fcc9801fe22 Mon Sep 17 00:00:00 2001 From: Cyrille Bougot Date: Mon, 16 Mar 2026 14:32:11 +0100 Subject: [PATCH 2/5] Add .egg-info to .git-ignore --- .gitignore | 1 + 1 file changed, 1 insertion(+) diff --git a/.gitignore b/.gitignore index 0be8af1..a6ccee5 100644 --- a/.gitignore +++ b/.gitignore @@ -9,3 +9,4 @@ manifest.ini *.nvda-addon .sconsign.dblite /[0-9]*.[0-9]*.[0-9]*.json +*.egg-info From d5f7cd7fdffc5d81404e76787b9d256dfc9ed2f3 Mon Sep 17 00:00:00 2001 From: Cyrille Bougot Date: Mon, 16 Mar 2026 14:50:10 +0100 Subject: [PATCH 3/5] Modernise uv usage (uv sync) + use uv for all python commands --- .github/workflows/build_addon.yml | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/.github/workflows/build_addon.yml b/.github/workflows/build_addon.yml index 9a60df1..b66fe8a 100644 --- a/.github/workflows/build_addon.yml +++ b/.github/workflows/build_addon.yml @@ -22,19 +22,19 @@ jobs: uses: actions/checkout@v6 - name: Install uv uses: astral-sh/setup-uv@v7 - - name: Set up Python - run: uv python install + with: + enable-cache: true - name: Install dependencies run: | sudo apt-get update -y sudo apt-get install -y gettext - uv pip install + uv sync - name: Code checks - run: export SKIP=no-commit-to-branch; pre-commit run --all + run: export SKIP=no-commit-to-branch; uv run pre-commit run --all-files - name: building addon - run: scons && scons pot + run: uv run scons && uv run scons pot - uses: actions/upload-artifact@v7 with: From 31beeb34619beeec468a397f966c65098500cb2f Mon Sep 17 00:00:00 2001 From: Cyrille Bougot Date: Mon, 16 Mar 2026 15:32:36 +0100 Subject: [PATCH 4/5] Update readme.md --- readme.md | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/readme.md b/readme.md index 117eb2c..df61be9 100644 --- a/readme.md +++ b/readme.md @@ -89,10 +89,15 @@ sconstruct and file: ``` .pre-commit-config.yaml +changelog.md +pyproject.toml +uv.lock ``` 4. Create an `addon` folder inside your new folder. You will put your code in the usual folders for NVDA extensions, under the `addon` folder. For instance: `globalPlugins`, `synthDrivers`, etc. -5. In the `buildVars.py` file, change variable `addon_info` with your add-on's information (name, summary, description, version, author, url, source url, license, and license URL). Also, be sure to carefully set the paths contained in the other variables in that file. If you need to use custom Markdown extensions, original add-on interface language is not English, or include custom braille translations tables, be sure to fil out markdown list, base language variable, and braille tables dictioanry, respectively. +5. In the `buildVars.py` file, change variable `addon_info` with your add-on's information (name, summary, description, version, author, url, source url, license, and license URL). Also, be sure to carefully set the paths contained in the other variables in that file. If you need to use custom Markdown extensions, original add-on interface language is not English, or include custom braille translations tables, be sure to fil out markdown list, base language variable, and braille tables dictionary, respectively. 6. Gettext translations must be placed into `addon\locale\/LC_MESSAGES\nvda.po`. +7. If you create releases with the GitHub workflow, pushing a tag, update the `changelog.md` file with the release description you want to be displayed in on your GitHub release page. +8. In the `[project]` section of `pyproject.toml`, update your project information. #### Add-on manifest specification @@ -102,7 +107,7 @@ An add-on manifest generated manually or via `buildVars.py` must include the fol * Summary (string): name as shown on NVDA's Add-on store. * Description (string): a short detailed description about the add-on. * Version (string), ideally number.number with an optional third number, denoting major.minor.patch. -* Changelog (string): changes between previous and current add-on releases. +* Changelog (string): changes between previous and current add-on releases, visible in the Add-on Store. * Author (string and an email address): one or more add-on author contact information in the form "name ". * URL (string): a web address where the add-on information can be found such as add-on repository. * docFileName (string): name of the documentation file. From 3989683039200cbe5100b3b2d72ecfe0897a4368 Mon Sep 17 00:00:00 2001 From: Cyrille Bougot Date: Mon, 16 Mar 2026 17:26:02 +0100 Subject: [PATCH 5/5] Added explanation comment --- .github/workflows/build_addon.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/build_addon.yml b/.github/workflows/build_addon.yml index b66fe8a..97519e4 100644 --- a/.github/workflows/build_addon.yml +++ b/.github/workflows/build_addon.yml @@ -13,6 +13,8 @@ on: jobs: build: + # Building the add-on template as an add-on does not make sense (and fails). + # Do not modify this repo name with your own one! (should remain the template) if: github.repository != 'nvaccess/addonTemplate' runs-on: ubuntu-latest