X-Git-Url: https://plomlompom.com/repos/foo.html?a=blobdiff_plain;ds=inline;f=jessie_start.sh;h=74044600838c62eb0009951661a76ea92a655181;hb=bee8337965d1635a2d87372fd04d78f3dde292f9;hp=2ff5336a454df2ed6e15c97933f4631417d8bd8c;hpb=a01c879a216ecdfc4b755b4cdf6037a0d8217445;p=config
diff --git a/jessie_start.sh b/jessie_start.sh
index 2ff5336..7404460 100755
--- a/jessie_start.sh
+++ b/jessie_start.sh
@@ -1,5 +1,6 @@
#!/bin/sh
set -x
+set -e
# Post-installation reduction. (Answer "no" to GRUB question.)
dpkg-query -Wf '${Package} ${Priority}\n' | grep ' required' | sed 's/ required//' > list_white_unsorted
@@ -13,7 +14,7 @@ comm -3 list_all_packages list_white > list_black
apt-mark auto `cat list_black`
echo 'APT::AutoRemove::RecommendsImportant "false";' > /etc/apt/apt.conf.d/99mindeps
echo 'APT::AutoRemove::SuggestsImportant "false";' >> /etc/apt/apt.conf.d/99mindeps
-apt-get -y --purge autoremove
+DEBIAN_FRONTEND=noninteractive apt-get -y --purge autoremove
rm list_all_packages list_white_unsorted list_white list_black
echo 'APT::Install-Recommends "false";' >> /etc/apt/apt.conf.d/99mindeps
echo 'APT::Install-Suggests "false";' >> /etc/apt/apt.conf.d/99mindeps
@@ -29,15 +30,34 @@ apt-get -y dist-upgrade
# Don't clear boot messages on start up.
sed -i 's/^TTYVTDisallocate=yes$/TTYVTDisallocate=no/g' /etc/systemd/system/getty.target.wants/getty\@tty1.service
-# Console config. (locales: 146, 1; console-setup: 27, 11, 1, 4)
-apt-get -y install locales console-setup
-dpkg-reconfigure locales
-dpkg-reconfigure console-setup
+# Console config.
+DEBIAN_FRONTEND=nointeractive apt-get -y install locales console-setup
+echo 'ACTIVE_CONSOLES="/dev/tty[1-6]"' > /etc/default/console-setup
+echo 'CHARMAP="UTF-8"' >> /etc/default/console-setup
+echo 'CODESET="Lat15"' >> /etc/default/console-setup
+echo 'FONTFACE="TerminusBold"' >> /etc/default/console-setup
+echo 'FONTSIZE="8x16"' >> /etc/default/console-setup
+echo 'en_US.UTF-8 UTF-8' >> /etc/locale.gen
+locale-gen
echo 'export LC_ALL="en_US.UTF-8"' >> /etc/profile
-apt-get -y install xserver-xorg xinit i3
-# Install certificates.
+# Clone git repository.
apt-get -y install ca-certificates
+apt-get -y install git
+git clone http://github.com/plomlompom/config
+config/symlink.sh
# Add user.
-#useradd -m -s /bin/bash plom
+useradd -m -s /bin/bash plom
+cp -R config /home/plom/
+chown -R plom /home/plom/config
+su plom -c /home/plom/config/symlink.sh
+
+# Set up window system.
+apt-get -y install xserver-xorg xinit i3 i3status
+
+# Clean up.
+rm jessie_start.sh
+
+# Set password for user.
+passwd plom