mirror of
https://github.com/Security-Onion-Solutions/securityonion.git
synced 2025-12-06 09:12:45 +01:00
[fix] Don't let grep output message on file not found
This commit is contained in:
@@ -771,7 +771,7 @@ disable_auto_start() {
|
||||
logCmd "crontab -u $INSTALLUSERNAME -r"
|
||||
fi
|
||||
|
||||
if grep -q so-setup /home/$INSTALLUSERNAME/.bash_profile; then
|
||||
if grep -s -q so-setup /home/$INSTALLUSERNAME/.bash_profile; then
|
||||
# Truncate last line of the bash profile
|
||||
info "Removing auto-run of setup from bash profile"
|
||||
sed -i '$ d' /home/$INSTALLUSERNAME/.bash_profile >> "$setup_log" 2>&1
|
||||
|
||||
Reference in New Issue
Block a user