summarylogtreecommitdiffstats
path: root/tcsh.install
blob: 04d5f4deaac36fc0bc9bbc733ab6c3fbef093b25 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
post_install() {
  if ! grep -qe '^/bin/tcsh$' etc/shells; then
    echo /bin/tcsh >>etc/shells
    echo /bin/csh >>etc/shells
    echo 'Added tcsh and csh to /etc/shells.'
  fi
}

pre_remove() {
  sed -i -r '/^(\/usr)?\/bin\/tcsh$/d' /etc/shells
  sed -i -r '/^(\/usr)?\/bin\/csh$/d' /etc/shells
  echo 'Removed tcsh and csh from /etc/shells.'
}