mirror of
https://github.com/Alvin-Zilverstand/return-youtube-dislike.git
synced 2026-09-12 09:58:20 +02:00
67 lines
1.7 KiB
Markdown
67 lines
1.7 KiB
Markdown
|
|
# AMO Source Build Instructions
|
||
|
|
|
||
|
|
This source package is provided for Mozilla Add-ons review. The extension is built with webpack, so reviewers should rebuild the submitted source and compare the generated Firefox output with the uploaded add-on package.
|
||
|
|
|
||
|
|
## Build environment
|
||
|
|
|
||
|
|
The release was built with:
|
||
|
|
|
||
|
|
- Ubuntu 24.04-compatible environment
|
||
|
|
- Node.js 22.17.0
|
||
|
|
- npm 10.8.2
|
||
|
|
|
||
|
|
The build script is cross-platform and also works on Windows and macOS when the same Node.js and npm versions are installed.
|
||
|
|
|
||
|
|
## Install Node.js
|
||
|
|
|
||
|
|
Using `nvm`:
|
||
|
|
|
||
|
|
```sh
|
||
|
|
nvm install 22.17.0
|
||
|
|
nvm use 22.17.0
|
||
|
|
```
|
||
|
|
|
||
|
|
Confirm the versions:
|
||
|
|
|
||
|
|
```sh
|
||
|
|
node --version
|
||
|
|
npm --version
|
||
|
|
```
|
||
|
|
|
||
|
|
Expected versions:
|
||
|
|
|
||
|
|
```text
|
||
|
|
v22.17.0
|
||
|
|
10.8.2
|
||
|
|
```
|
||
|
|
|
||
|
|
## Build
|
||
|
|
|
||
|
|
From the repository root, run:
|
||
|
|
|
||
|
|
```sh
|
||
|
|
node scripts/build-firefox-source.mjs
|
||
|
|
```
|
||
|
|
|
||
|
|
The script performs all required technical build steps:
|
||
|
|
|
||
|
|
1. Installs dependencies with `npm ci`.
|
||
|
|
2. Builds the extension with `npm run build`.
|
||
|
|
3. Verifies the generated Firefox output exists.
|
||
|
|
4. Verifies `ryd.content-script.js` is below 5 MB and does not contain a source map reference.
|
||
|
|
|
||
|
|
The generated Firefox extension files are written to:
|
||
|
|
|
||
|
|
```text
|
||
|
|
Extensions/combined/dist/firefox
|
||
|
|
```
|
||
|
|
|
||
|
|
Use that directory when comparing the rebuilt code with the submitted Firefox add-on package.
|
||
|
|
|
||
|
|
## Notes
|
||
|
|
|
||
|
|
- `package-lock.json` is included so npm installs the same dependency versions used for this release.
|
||
|
|
- Production builds disable inline source maps. Development builds still use inline source maps through `npm run dev`.
|
||
|
|
- The production bundle is generated by webpack but is not intentionally obfuscated or minified.
|
||
|
|
- `node_modules` and `Extensions/combined/dist` are generated locally and are not source inputs.
|