home · contact · privacy
In Buster setup, also pre-install Firefox add-ons.
authorChristian Heller <c.heller@plomlompom.de>
Mon, 8 Apr 2019 00:51:34 +0000 (02:51 +0200)
committerChristian Heller <c.heller@plomlompom.de>
Mon, 8 Apr 2019 00:51:34 +0000 (02:51 +0200)
buster/apt-mark/eeepc
buster/setup_scripts/setup_eeepc.sh

index c7885a5ab3c70b491d40cd69c5af5718e62ba5d0..b395f0fce550b83365eb361329e954ebe393e1f5 100644 (file)
@@ -39,3 +39,5 @@ libgtk-3-0
 # firefox installation dependencies (remove later?)
 bzip2
 wget
+jq
+#
index 76cb379282138aedd8d1772a3368429b25e5f049..ef378f0477688a06aecd1e510b93a421f70364a7 100755 (executable)
@@ -7,6 +7,7 @@ if [ "$#" -ne 1 ]; then
 fi
 hostname="$1"
 
+# Set up system without user environment.
 config_tree_prefix="${HOME}/config/buster"
 setup_scripts_dir="${config_tree_prefix}/setup_scripts"
 cd "${setup_scripts_dir}"
@@ -14,6 +15,7 @@ cd "${setup_scripts_dir}"
 ./copy_dirtree.sh "${config_tree_prefix}/etc_files" "" eeepc
 ./install_for_target.sh eeepc
 
+# Install Firefox directly from Mozilla.
 url_firefox="https://ftp.mozilla.org/pub/firefox/releases/66.0/linux-x86_64/en-US/firefox-66.0.tar.bz2"
 wget "${url_firefox}"
 mv firefox-66.0.tar.bz2 /opt/
@@ -23,8 +25,23 @@ rm firefox-66.0.tar.bz2
 ln -s /opt/firefox/firefox /usr/local/bin/
 update-alternatives --install /usr/bin/x-www-browser x-www-browser /opt/firefox/firefox 200
 update-alternatives --set x-www-browser /opt/firefox/firefox
-cd "${setup_scripts_dir}"
 
+# Install Firefox plugins.
+# See <https://developer.mozilla.org/en-US/docs/Mozilla/Add-ons/WebExtensions/Distribution_options/Sideloading_add-ons>
+extensions_dir="/usr/share/mozilla/extensions/{ec8030f7-c20a-464f-9b0e-13a3a9e97384}/"
+noscript_xpi="noscript-10.6.xpi"
+url_noscript="https://secure.informaction.com/download/releases/${noscript_xpi}"
+wget "${url_noscript}"
+name=$(unzip -p "${noscript_xpi}" manifest.json | jq -r .applications.gecko.id)
+mv "${noscript_xpi}" "${name}.xpi"
+tridactyl_xpi="tridactyl-1.14.9pre2457-an+fx.xpi"
+url_tridactyl="https://tridactyl.cmcaine.co.uk/betas/${tridactyl_xpi}"
+name=$(unzip -p "${tridactyl_xpi}" manifest.json | jq -r .applications.gecko.id)
+mv "${tridactyl_xpi}" "${name}.xpi"
+mv *.xpi "${extensions_dir}"
+
+# Set up user environments.
+cd "${setup_scripts_dir}"
 ./copy_dirtree.sh "${config_tree_prefix}/home_files" "/root" minimal root
 if [ ! -d "/home/plom" ]; then
     adduser --disabled-password --gecos "" plom