X-Git-Url: https://plomlompom.com/repos/foo.html?a=blobdiff_plain;ds=sidebyside;f=buster%2Fsetup_scripts%2Fsetup_desktop.sh;h=97488e1977314d11ff50a2f73a5dff7516880629;hb=1051f875935af7ecda03a8164013c8849039d92a;hp=b76fa5656de30cd131a7b1d67c1987f9db674f64;hpb=72d0c7ff45225d7e122f752a95b24a126d5545ff;p=config
diff --git a/buster/setup_scripts/setup_desktop.sh b/buster/setup_scripts/setup_desktop.sh
index b76fa56..97488e1 100755
--- a/buster/setup_scripts/setup_desktop.sh
+++ b/buster/setup_scripts/setup_desktop.sh
@@ -5,7 +5,7 @@ if [ "$#" -ne 1 ]; then
echo 'Need exactly one argument (system name).'
false
fi
-if [ ! "$1" = "eeepc" ] && [ ! "$1" = "x200s" ]; then
+if [ ! "$1" = "eeepc" ] && [ ! "$1" = "x200s" ] && [ ! "$1" = "x220" ] && [ ! "$1" = "w530" ]; then
echo "Need legal system name."
false
fi
@@ -15,12 +15,23 @@ system_name="$1"
config_tree_prefix="${HOME}/config/buster"
setup_scripts_dir="${config_tree_prefix}/setup_scripts"
cd "${setup_scripts_dir}"
-./setup.sh "${system_name}" ""
-./copy_dirtree.sh "${config_tree_prefix}/etc_files" "" user "${system_name}"
-./install_for_target.sh user "${system_name}"
+if [ "$1" = "x200s" ] || [ "$1" = "x220" ] || [ "$1" = "w530" ]; then
+ ./setup.sh "${system_name}" "" user desktop thinkpad "${system_name}"
+else
+ ./setup.sh "${system_name}" "" user desktop "${system_name}"
+fi
+# For hibernation on lid switch to work, we need a newer kernel on the EeePC,
+# see .
+if [ "${system_name}" = "eeepc" ]; then
+ apt -y install -t buster-backports linux-image-amd64
+fi
+
+# Set up printer.
+lpadmin -p 'HP_Deskjet_F300_series' -m 'drv:///hpcups.drv/hp-deskjet_f300_series.ppd' -o 'OutputMode=NormalGray' -E
+service cups restart
# Install Firefox directly from Mozilla.
-firefox_release="68.0esr"
+firefox_release="68.4.1esr"
firefox_filename="firefox-${firefox_release}.tar.bz2"
url_firefox="https://ftp.mozilla.org/pub/firefox/releases/${firefox_release}/linux-x86_64/en-US/${firefox_filename}"
wget "${url_firefox}"
@@ -36,17 +47,14 @@ update-alternatives --set x-www-browser /opt/firefox/firefox
# See
extensions_dir="/usr/share/mozilla/extensions/{ec8030f7-c20a-464f-9b0e-13a3a9e97384}/"
mkdir -p "${extensions_dir}"
-umatrix_xpi="uMatrix.firefox.signed.xpi"
-url_umatrix="https://github.com/gorhill/uMatrix/releases/download/1.3.17rc4/${umatrix_xpi}"
+umatrix_version="1.4.0"
+umatrix_xpi="uMatrix.firefox.xpi"
+url_umatrix="https://github.com/gorhill/uMatrix/releases/download/${umatrix_version}/${umatrix_xpi}"
wget "${url_umatrix}"
name=$(unzip -p "${umatrix_xpi}" manifest.json | jq -r .applications.gecko.id)
mv "${umatrix_xpi}" "${name}".xpi
-#noscript_xpi="noscript-11.0.2.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-latest.xpi"
+tridactyl_version="1.17.1pre3355"
+tridactyl_xpi="tridactyl_beta-${tridactyl_version}-an+fx.xpi"
url_tridactyl="https://tridactyl.cmcaine.co.uk/betas/${tridactyl_xpi}"
wget "${url_tridactyl}"
name=$(unzip -p "${tridactyl_xpi}" manifest.json | jq -r .applications.gecko.id)
@@ -59,7 +67,9 @@ source_dir_secrets="/media/${secrets_dev}/to_usb"
target_dir_secrets="/home/plom/tmp_secrets"
cd "${setup_scripts_dir}"
./copy_dirtree.sh "${config_tree_prefix}/home_files" "/root" minimal root
+set +e
HOME_DIR_EXISTS=$([ ! -d "/home/plom" ]; echo $?)
+set -e
adduser --disabled-password --gecos "" plom
usermod -a -G sudo plom
passwd plom
@@ -79,6 +89,6 @@ if [ "${HOME_DIR_EXISTS}" -eq 0 ]; then
pumount "${secrets_dev}"
echo "You can remove /dev/${secrets_dev} now."
cp setup_home.sh /home/plom
- chown plom:plom /home/plom/setup_home_eeepc.sh
+ chown plom:plom /home/plom/setup_home.sh
SECRETS_PASS="${secrets_pass}" su -c "cd && ./setup_home.sh ${system_name}" plom
fi