diff options
Diffstat (limited to 'sh/profile.d')
-rw-r--r-- | sh/profile.d/grep.sh | 2 | ||||
-rw-r--r-- | sh/profile.d/ls.sh | 12 |
2 files changed, 10 insertions, 4 deletions
diff --git a/sh/profile.d/grep.sh b/sh/profile.d/grep.sh index d1ef3ba1..d6f9c36b 100644 --- a/sh/profile.d/grep.sh +++ b/sh/profile.d/grep.sh @@ -20,7 +20,7 @@ exclude \ exclude-dir for opt ; do - grep -Eq -- --"$opt" "$gcd"/help || continue + grep -q -- --"$opt" "$gcd"/help || continue touch -- "$gcd"/"$opt" || exit done fi diff --git a/sh/profile.d/ls.sh b/sh/profile.d/ls.sh index 0c3754e9..8a255bee 100644 --- a/sh/profile.d/ls.sh +++ b/sh/profile.d/ls.sh @@ -13,8 +13,14 @@ # Iterate through some useful options and create files to show they're # available - if grep -q -- --color "$lcd"/help ; then - touch -- "$lcd"/color || exit - fi + set -- block-size \ + classify \ + color \ + human-readable \ + time-style + for opt ; do + grep -q -- --"$opt" "$lcd"/help || continue + touch -- "$lcd"/"$opt" || exit + done fi ) |