Skip to content
Snippets Groups Projects

fix cut command containing = character

Merged Hahn Axel (hahn) requested to merge fix_cut_commandline into master
1 file
+ 4
4
Compare changes
  • Side-by-side
  • Inline
+ 4
4
@@ -110,11 +110,11 @@
@@ -110,11 +110,11 @@
# icon=/images/icon.png
# icon=/images/icon.png
# max_check_attempts=3
# max_check_attempts=3
checkName=$(cat "$_myconfig" | grep ^checkname= | cut -f 2 -d "=" | sed 's# #_#g')
checkName=$(cat "$_myconfig" | grep ^checkname= | cut -f 2- -d "=" | sed 's# #_#g')
checkCommand=$(cat "$_myconfig" | grep ^command_$MY_NAME= | cut -f 2 -d "=")
checkCommand=$(cat "$_myconfig" | grep ^command_$MY_NAME= | cut -f 2- -d "=")
test -z "$checkCommand" && checkCommand=$(cat "$_myconfig" | grep ^command= | cut -f 2 -d "=")
test -z "$checkCommand" && checkCommand=$(cat "$_myconfig" | grep ^command= | cut -f 2- -d "=")
checkInterval=$(cat "$_myconfig" | grep ^interval= | cut -f 2 -d "=")
checkInterval=$(cat "$_myconfig" | grep ^interval= | cut -f 2 -d "=")
checkIcon=$(cat "$_myconfig" | grep ^icon= | cut -f 2 -d "=")
checkIcon=$(cat "$_myconfig" | grep ^icon= | cut -f 2- -d "=")
checkMaxAttempts=$(cat "$_myconfig" | grep ^max_check_attempts= | cut -f 2 -d "=")
checkMaxAttempts=$(cat "$_myconfig" | grep ^max_check_attempts= | cut -f 2 -d "=")
}
}
Loading