miscellaneous.md
May 29, 2025 ยท View on GitHub
Miscellaneous
Changing dependencies
Whenever you change dependencies (adding, removing, or updating, either in package.json or yarn.lock), there are various files that must be kept up-to-date.
-
yarn.lock:- Run
yarn setupagain after your changes to ensureyarn.lockhas been properly updated.
- Run
-
The
allow-scriptsconfiguration inpackage.json- Run
yarn allow-scripts autoto update theallow-scriptsconfiguration automatically. This config determines whether the package's install/postinstall scripts are allowed to run. Review each new package to determine whether the install script needs to run or not, testing if necessary. - Unfortunately,
yarn allow-scripts autowill behave inconsistently on different platforms. macOS and Windows users may see extraneous changes relating to optional dependencies.
- Run
-
The Attributions file
- If you are a MetaMask team member and your PR is on a repository branch, you can use the bot command
@metamaskbot update-attributionsto ask the MetaMask bot to automatically update the attributions file for you. - Manual update: run
yarn build:attribution.
- If you are a MetaMask team member and your PR is on a repository branch, you can use the bot command