remove_launcher: just keep any comments, instead of duplicating/printing

them.
This commit is contained in:
Daniel Hahler 2011-09-29 09:27:08 +02:00
commit 4501fcf3ab

View file

@ -25,8 +25,8 @@ PKG="byobu"
remove_launcher() { remove_launcher() {
dest=$1 dest=$1
if [ -w "$dest" ]; then if [ -w "$dest" ]; then
# print any comments, and remove lines invoking byobu: # keep any comments, and remove lines invoking byobu:
$SED -i -e '/^\s*#/p' -e "/\b$PKG-launch\$/d" -e "/ screen-launch/d" "$dest" $SED -i -e '/^\s*#/n' -e "/\b$PKG-launch\$/d" -e "/ screen-launch/d" "$dest"
fi fi
} }