docs: reproducible build steps with exact tool versions

This commit is contained in:
Oliver_Herb committed 2026-11-24 12:10:30 +01:00
1 parent 9053327486
commit 6b277f97b3
2 files changed
+39 -1

No files matched your search

+38
View File
@@ -43,6 +43,44 @@ Node).
The `.xpi` is a plain ZIP of `src/` plus the `LICENSE` file. There is no bundler, no transpiler and
no minification: every file from `src/` goes into the package unchanged.
## Reproducible build (for add-on reviewers)
Because the package contains no generated code, addons.thunderbird.net does not require a source
archive. These steps are provided anyway, so anyone can rebuild a release and compare it.
**Environment used for release 0.2.0:** Debian GNU/Linux 13 (trixie), x86_64, Node.js 24.22.1,
npm 11.19.1, Zip 3.0 (Info-ZIP), GNU bash 5.2.37. Any Linux or macOS works; on Windows use WSL.
**Install the tools:**
- Debian/Ubuntu (also inside WSL on Windows): `sudo apt install git zip`, then Node.js 22 or later
from <https://nodejs.org/en/download> (or `sudo apt install nodejs npm` if the distribution ships
Node.js 22 or later; check with `node --version`).
- macOS: bash and zip are preinstalled; install git and Node.js 22 or later, e.g.
`brew install git node`.
**Build:**
```bash
git clone https://git.hassio-muc.de/Oliver_Herb/inline-comment.git
cd inline-comment
git checkout v0.2.0 # the tag of the release to rebuild
bash scripts/build.sh # packs dist/inline-comment-0.2.0.xpi; needs only bash, zip and node
```
`bash scripts/build.sh` is the complete build script: it reads the version from
`src/manifest.json`, zips `src/` and adds `LICENSE`. No `npm install` is needed for it. To run all
checks before packaging, use `npm ci && npm run build` instead (`npm ci` installs the exact
development tool versions from `package-lock.json`).
**Compare with a published package** (the ZIP file itself differs because of file timestamps, the
contents are identical):
```bash
mkdir /tmp/xpi && unzip -q -d /tmp/xpi inline-comment-0.2.0.xpi
diff -r -x LICENSE /tmp/xpi src && cmp /tmp/xpi/LICENSE LICENSE && echo identical
```
## Repository layout
| Path | Content |