diff options
Diffstat (limited to 'tmw-info')
-rwxr-xr-x | tmw-info | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -41,7 +41,7 @@ help(){ echo " gm-search TERM1 TERM2 TERM3 ... (results contain any of the terms)" echo " gm-asearch TERM1 TERM2 TERM3 ... (results contain all of the terms)" echo " gm-esearch TERM1 TERM2 TERM3 ... (results contain the exact term)" - echo " gm-show (if zenity is installed, displays a GUI pop-up of the last 10 issued GM CMDs, otherwise in terminal)" + echo " gm-show (if zenity is installed, displays a GUI pop-up of the last 10 issued GM CMDs), otherwise in terminal" echo " item-update (downloads item DB. Must be run before searching)" echo " item-search TERM1 TERM2 TERM3 ... (items: results contain all of the terms)" echo " mob-update (downloads monster DB. Must be run before searching)" @@ -209,7 +209,7 @@ elif [ "$1" == 'gm-show' ]; then fi fi fi - if [[ $(dpkg -l 'zenity' | awk '{print $1}') == 'ii' ]]; then + if [[ $(dpkg -l 'zenity' | grep -Eo '^ii') == 'ii' ]]; then zenity --text-info 'tmw-gmlog' --width '600' --height '300' --filename "$GM_REPORT" else cat < "$GM_REPORT" @@ -329,7 +329,7 @@ elif [ "$1" == "mob-search" ]; then mv "$TMW_INFO/mob-drops-$MOB_ID.tmp.tmp" "$TMW_INFO/mob-drops-$MOB_ID.tmp" DROP_COUNT=$(( DROP_COUNT + 1 )) done - DROPS=$(cat < "$TMW_INFO/mob-drops-$MOB_ID.tmp" | sed 's/^$//g') + DROPS=$(cat < "$TMW_INFO/mob-drops-$MOB_ID.tmp" | sed 's/^$//g' | sed -E 's/,\s*$//g') echo -e "\ ID: $(echo "$LINE" | awk '{print $1}') NAME: $(echo "$LINE" | awk '{print $2 $3}') LVL: $(echo "$LINE" | awk '{print $4}')\n\ HP: $(echo "$LINE" | awk '{print $5}') SP: $(echo "$LINE" | awk '{print $6}') \ |