Files
gvm/scripts/function/tools
T
Ali Abbas c1ec392bdd - Double quoting to avoid globbing
- Remove unecessary $(cat)
- switch * to ./* to avoid entries with dashes to be treated as options
- replace $* with "$@"
- repeating change path serial calls - unecessary if change path is called one (get script)
2014-04-12 15:56:54 +02:00

12 lines
530 B
Bash

#!/usr/bin/env bash
LS_ERROR="GVM couldn't find ls"
GREP_ERROR="GVM couldn't find grep"
SORT_ERROR="GVM couldn't find sort"
HEAD_ERROR="GVM couldn't find head"
LS_PATH=$(unalias ls &> /dev/null; which ls) || display_error "$LS_ERROR" || return 1
GREP_PATH=$(unalias grep &> /dev/null; which grep) || display_error "$GREP_ERROR" || return 1
SORT_PATH=$(unalias sort &> /dev/null; which sort) || display_error "$SORT_ERROR" || return 1
HEAD_PATH=$(unalias head &> /dev/null; which head) || display_error "$HEAD_ERROR" || return 1