post_install() {
  grep -Fqx /bin/elvish /etc/shells || echo /bin/elvish >> /etc/shells
  grep -Fqx /usr/bin/elvish /etc/shells || echo /usr/bin/elvish >> /etc/shells
}

post_upgrade() {
  post_install
}

pre_remove() {
  sed -i -r '/^(\/usr)?\/bin\/elvish$/d' etc/shells
}

# vim:set ts=2 sw=2 et:
