Explorar el Código

update function s

pull/1/head
10sr hace 11 años
padre
commit
eb5e027601
Se han modificado 1 ficheros con 6 adiciones y 5 borrados
  1. +6
    -5
      bashrc

+ 6
- 5
bashrc Ver fichero

@@ -315,16 +315,17 @@ s(){

if git rev-parse --git-dir >/dev/null 2>&1
then
git grep -n "$1"
git grep -n "$@"
elif which ag >/dev/null
then
ag --pager="$PAGER" "$1"
ag --pager="$PAGER" "$@"
elif which ack >/dev/null
then
ack --pager="$PAGER" "$1"
ack --pager="$PAGER" "$@"
else
echo "No search command found. Use grep." 2>&1
return 127
grep -nH --exclude='.svn/*' --exclude='.git/*' "$@" -r . | $PAGER
# echo "No search command found. Use grep." 2>&1
# return 127
fi
}



Cargando…
Cancelar
Guardar