File tree Expand file tree Collapse file tree 1 file changed +30
-0
lines changed
Expand file tree Collapse file tree 1 file changed +30
-0
lines changed Original file line number Diff line number Diff line change 1+ #! /usr/bin/sh
2+
3+ # Local development workaround for Firefox.
4+ #
5+ # Once you build this extension (with `npm install` and `npm run build`, as per <README.md>), to
6+ # load it, visit Firefox special URL about:debugging#/runtime/this-firefox. Click button "Load
7+ # Temporary Add-on..." That button shows a file/folder picker.
8+ #
9+ # Problem: The file picker does allow you to select `manifest.firefox.json`, BUT it will not load
10+ # it. It loads `manifest.json` (from the directory where you selected `manifest.firefox.json`)
11+ # instead. (Indeed, a Firefox defect - but life is too short for us to waste it on Mozilla's
12+ # bugzilla....)
13+ #
14+ # Firefox doesn't allow to use symlinks to workaround the above problem (see
15+ # https://bugzilla.mozilla.org/show_bug.cgi?id=803999 - symlinks are a security problem).
16+ #
17+ # Workaround: This script
18+ # 1. copies manifest.firefox.json over manifest.json
19+ # 2. prevents that change from being accidentally committed to GIT.
20+
21+ # Enter the directory where this script is (in case we call it from somewhere else).
22+ cd " ${0%/* } "
23+
24+ # Invoking `/usr/bin/cp` directly, in case there's an alias that warns about overriding existing
25+ # files.
26+ /usr/bin/cp manifest.firefox.json manifest.json
27+
28+ # See also
29+ # https://stackoverflow.com/questions/13630849/git-difference-between-assume-unchanged-and-skip-worktree
30+ git update-index --skip-worktree manifest.json
You can’t perform that action at this time.
0 commit comments