# in case we need it,
# to make ssh interactive shell run better, we run this first.
-sudo bash -c 'source /a/c/repos/bash/.bashrc && source /a/exe/ssh-emacs-setup'
+sudo bash -c 'source /a/c/.bashrc && source /a/exe/ssh-emacs-setup'
# usage: $0 [-r] HOSTNAME
# already ran for pxe installs, but used for vps & updates
distro=$(distro-name)
case $distro in
- ubuntu|debian)
+ ubuntu|debian|trisquel)
sudo bash -c ". /a/bin/fai/fai-wrapper && /a/bin/fai/fai/config/scripts/GRUB_PC/11-ian"
;;
*)
fi
+#### begin link bashrc for root ######
+for x in /a/c/{.bashrc,brc,.bash_profile,.profile,.inputrc,path_add_function}; do
+ sudo -i <<EOF
+PATH="/a/exe:$PATH"
+lnf $x /root
+EOF
+done
+#### end link bashrc repo for root ######
# this needs to be before installing pacserve so we have gpg conf.
conflink
set +x
errallow
+source /etc/profile.d/environment.sh
source ~/.bashrc
$interactive || errcatch
$interactive || set -x
tu /etc/sudoers <<'EOF'
ian ALL=(ALL) NOPASSWD: ALL
Defaults env_keep += SUDOD
+# makes ubuntu be like debian
+# https://unix.stackexchange.com/a/91572
+Defaults always_set_home
EOF
isfedora && tu /etc/sysctl.conf 'kernel.sysrq = 1'
-if isdebian; then
- codename=$(debian-codename)
+if isdeb; then
if isdebian-stable && has_x; then
+ codename=$(debian-codename)
s dd of=/etc/apt/sources.list.d/mozilla-iceweasel.list <<EOF
deb http://mozilla.debian.net/ $codename-backports firefox-release
deb-src http://mozilla.debian.net/ $codename-backports firefox-release
s lnf -T /a/bin /b
+s lnf -T /nocow/t /t
if has_p; then
lnf -T /p/News ~/News
rootsshsync
-s lnf /a/c/.inputrc /a/c/.vim /a/c/.vimrc /a/c/.gvimrc /root
+s lnf /a/c/.vim /a/c/.vimrc /a/c/.gvimrc /root
# machine is going away
# if [[ $HOSTNAME == htpc ]]; then
pi $p
fi
;;&
- ubuntu|debian)
+ trisquel|ubuntu|debian)
if has_x; then
- if isdebian-stable; then
- pi xmacro
- else
+ if isdebian-testing; then
pi xmacro/unstable # has no unstable deps
+ else
+ pi xmacro
fi
pi gtk-redshift xinput
fi
fi
;;&
- ubuntu|debian|fedora)
+ ubuntu|trisquel|debian|fedora)
if has_x; then
- if isdebian-stable; then
- pi xkbset
- else
+ if isdebian-testing; then
# xkbset was in testing for quite a while, dunno
# why it\'s not anymore. Sometime I should check and
# see if it\'s back in testing, but the unstable package
# doesn\'t upgrade anything form testing, and it\'s tiny
# so I\'m not bothering to automate it.
pi xkbset/unstable
+ else
+ pi xkbset
fi
fi
;;&
s dd of=/etc/systemd/system/imount.service <<'EOF'
[Unit]
Description=Mount /i and related mountpoints
+Before=syncthing@ian.service
[Service]
Type=oneshot
ExecStart=/root/imount
[Install]
+RequiredBy=syncthing@ian.service
# note /kr needs networking, this target is the simplest way to
# time it when the network should be up, but not do something
# dumb like delay startup until the network is up. It happens
fi
if isubuntu; then
- # disable crash report annoying crap
+ # disable crash report annoying dialogs.
s dd of=/etc/default/apport <<<'enabled=0'
fi
fi
pi dmenu
- if isdeb && (tp || x2); then
- pi task-laptop
+ if tp || x2; then
+ case $distro in
+ debian)
+ pi task-laptop
+ ;;
+ ubuntu|trisquel)
+ # the exact packages that task-laptop would install, since ubuntu
+ # doesn\'t have this virtual in practice package.
+ pi avahi-autoipd bluetooth powertop iw wireless-tools wpasupplicant
+ ;;
+ # todo: other distros unknown
+ esac
fi
fi