remove old bashrc_add line

This commit is contained in:
Jakobus Schürz 2020-01-14 14:10:34 +01:00
parent 6737f6f5dd
commit 36b391dd54

View file

@ -228,8 +228,8 @@ sshmyshellconfig() {
[ -e /etc/bashrc ] && . /etc/bashrc
[ -e /etc/bash.bashrc ] && . /etc/bash.bashrc
echo "modify ~/.bashrc"
if grep -q bashrc_add ~/.bashrc ;then
sed -i -e '/bashrc_add/d' ~/.bashrc
if grep -q "[ -f ~/bashrc_add ] &&" ~/.bashrc ;then
sed -i -e '/\\[ -f ~/bashrc_add \\] &&/d' ~/.bashrc
fi
sed -i -e '/#MYSHELLCONFIG-start/,/#MYSHELLCONFIG-end/d' ~/.bashrc
echo