-
Notifications
You must be signed in to change notification settings - Fork 23
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Port to WebExtensions #48
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -47,7 +47,7 @@ ADDON_DATA = \ | |
addon/bootstrap.css addon/options.html addon/options.css addon/options.js \ | ||
addon/pref-setup.js | ||
|
||
default: build/betterponymotes.xpi build/chrome.zip build/BPM.safariextension build/export.json.bz2 | ||
default: build/betterponymotes.xpi build/chrome.zip build/firefox.zip build/BPM.safariextension build/export.json.bz2 | ||
|
||
clean: | ||
rm -fr build | ||
|
@@ -136,6 +136,32 @@ build/chrome.zip: $(ADDON_DATA) addon/cr-background.html addon/cr-background.js | |
# Uncompressed due to prior difficulties with the webstore | ||
cd build/chrome && zip -0 ../chrome.zip * | ||
|
||
build/firefox.zip: $(ADDON_DATA) addon/cr-background.html addon/cr-background.js | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Since we are unifying Chrome and WebExt, would like to rename these to |
||
mkdir -p build/firefox_webextension | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Similar complaint: long name, just call it |
||
|
||
sed "s/\/\*{{version}}\*\//$(VERSION)/" < addon/fx-manifest.json > build/firefox_webextension/manifest.json | ||
|
||
cp addon/cr-background.html build/firefox_webextension/background.html | ||
cp addon/cr-background.js build/firefox_webextension/background.js | ||
|
||
cp build/betterponymotes.js build/firefox_webextension | ||
cp build/bpm-resources.js build/firefox_webextension | ||
cp build/emote-classes.css build/firefox_webextension | ||
|
||
cp addon/bootstrap.css build/firefox_webextension | ||
cp addon/bpmotes.css build/firefox_webextension | ||
cp addon/combiners-nsfw.css build/firefox_webextension | ||
cp addon/extracss-pure.css build/firefox_webextension | ||
cp addon/extracss-webkit.css build/firefox_webextension | ||
cp addon/options.css build/firefox_webextension | ||
cp addon/options.html build/firefox_webextension | ||
cp addon/options.js build/firefox_webextension | ||
cp addon/pref-setup.js build/firefox_webextension | ||
|
||
cp betterponymotes.pem build/firefox_webextension/key.pem | ||
# Uncompressed due to prior difficulties with the webstore | ||
cd build/firefox_webextension && zip -0 ../firefox_webextension.xpi * | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Should be writing out |
||
|
||
build/BPM.safariextension: $(ADDON_DATA) addon/sf-Settings.plist addon/sf-background.html addon/sf-background.js | ||
mkdir -p build/BPM.safariextension | ||
|
||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
{ | ||
"background": { | ||
"page": "background.html" | ||
}, | ||
"content_scripts": [ | ||
{ | ||
"all_frames": true, | ||
"js": [ | ||
"bpm-resources.js", | ||
"betterponymotes.js" | ||
], | ||
"matches": [ | ||
"*://*/*" | ||
], | ||
"run_at": "document_start" | ||
} | ||
], | ||
"applications": { | ||
"gecko": { | ||
"id": "jid1-tHrhDJXsKvsiCw@jetpack" | ||
} | ||
}, | ||
"description": "View Reddit ponymotes across the site", | ||
"homepage_url": "https://ponymotes.net/bpm/", | ||
"manifest_version": 2, | ||
"minimum_chrome_version": "20", | ||
"name": "BetterPonymotes", | ||
"options_ui": { | ||
"page": "options.html", | ||
"browser_style": true | ||
}, | ||
"permissions": [ | ||
"http://*.reddit.com/", | ||
"https://*.reddit.com/", | ||
"http://*.redditstatic.com/", | ||
"https://*.redditstatic.com/", | ||
"http://*.redditmedia.com/", | ||
"https://*.redditmedia.com/" | ||
], | ||
"version": "/*{{version}}*/.mozsucks", | ||
"web_accessible_resources": [ | ||
"bpmotes.css", | ||
"emote-classes.css", | ||
"combiners-nsfw.css", | ||
"extracss-pure.css", | ||
"extracss-webkit.css", | ||
"options.html" | ||
] | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not that my target filenames are in any way sensible most of the time, but can we rename this to something less authoritative sounding like
webext.zip
? Or is there some particular utility to this name?