mirror of
https://github.com/notwa/rc
synced 2024-06-17 13:43:06 -07:00
allow executables in ~/sh to begin with hyphens
This commit is contained in:
parent
716d74ade2
commit
fdcae6182f
|
@ -38,7 +38,7 @@ ADDPATH "$HOME/sh"
|
|||
# unlike zsh, we do not check the sha1sum of the output.
|
||||
cd ~/sh \
|
||||
&& printf "%s\n" '#!/usr/bin/env false' '[ -n "$preload" ] || exit 1' '' \
|
||||
| cat - $(grep -lF 'YES_BASH' $(find ~/sh -maxdepth 1 -type f)) \
|
||||
| cat - $(grep -lF YES_BASH -- $(find ~/sh -maxdepth 1 -type f)) \
|
||||
> ~/.sh-bash
|
||||
)
|
||||
|
||||
|
|
|
@ -57,7 +57,7 @@ function {
|
|||
[ -s ~/.sh.sha1 ] && read -r b _ < ~/.sh.sha1
|
||||
( cd ~/sh \
|
||||
&& print -l '#!/usr/bin/env false' '[ -n "$preload" ] || exit 1' '' \
|
||||
| cat - $(grep -lF 'YES_ZSH' *~*.bak(.)) \
|
||||
| cat - $(grep -lF YES_ZSH -- *~*.bak(.)) \
|
||||
| tee ~/.sh \
|
||||
) | sha1sum - \
|
||||
| tee ~/.sh.sha1 \
|
||||
|
|
Loading…
Reference in New Issue
Block a user