1
0
mirror of https://git.FreeBSD.org/ports.git synced 2024-11-23 00:43:28 +00:00
freebsd-ports/Keywords/shell.ucl
Baptiste Daroussin 1cee61cab5 Convert keywords in pure ucl format
yaml version will be removed later
2014-07-24 17:10:57 +00:00

25 lines
798 B
Plaintext

# $FreeBSD$
#
# MAINTAINER: portmgr@FreeBSD.org
#
# @shell bin/shell
#
# Handle adding and remove a path to a shell binary into /etc/shells
# it replaces the following code:
#
# bin/shell
# @exec echo "Updating /etc/shells"; cp /etc/shells /etc/shells.bak; (grep -v %D/%F /etc/shells.bak; echo %D/%F) >/etc/shells; rm -f /etc/shells.bak
# @unexec echo "Updating /etc/shells"; cp /etc/shells /etc/shells.bak; (grep -v %D/%F /etc/shells.bak) >/etc/shells; rm -f /etc/shells.bak
actions: [file]
post-install: <<EOD
cp /etc/shells /etc/shells.bak
(grep -v %D/%@ /etc/shells.bak; echo %D/%@) > /etc/shells
rm -f /etc/shells.bak
EOD
pre-deinstall: <<EOD
cp /etc/shells /etc/shells.bak
grep -v %D/%@ /etc/shells.bak > /etc/shells
rm -f /etc/shells.bak
EOD