diff options
| author | 2015-08-06 22:24:44 +0000 | |
|---|---|---|
| committer | 2015-08-06 22:24:44 +0000 | |
| commit | e9015fb30f31f6c403cbd112a73795c439125ade (patch) | |
| tree | b7ea47474dfb060b959d92d50148369bb4e06e5f /bash | |
| parent | 390f41ebc5751db4fd1bc2af279eb58aa8ac5475 (diff) | |
| download | dotfiles-e9015fb30f31f6c403cbd112a73795c439125ade.tar.gz dotfiles-e9015fb30f31f6c403cbd112a73795c439125ade.tar.bz2 dotfiles-e9015fb30f31f6c403cbd112a73795c439125ade.zip | |
Made the sudo function FreeBSD compatible
Diffstat (limited to 'bash')
| -rwxr-xr-x | bash/.bashrc | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/bash/.bashrc b/bash/.bashrc index 3e9a0e2..e8a61fc 100755 --- a/bash/.bashrc +++ b/bash/.bashrc | |||
| @@ -67,7 +67,8 @@ if exists sudo; then | |||
| 67 | if is_function $1 2> /dev/null; then | 67 | if is_function $1 2> /dev/null; then |
| 68 | tmpfile="/tmp/$(date +%s).sh" | 68 | tmpfile="/tmp/$(date +%s).sh" |
| 69 | 69 | ||
| 70 | echo "#!$usr/bin/env bash" > "$tmpfile" | 70 | echo "#!$usr/bin/bash" > "$tmpfile" |
| 71 | echo "usr=$usr" >> "$tmpfile" | ||
| 71 | type $1 | grep -v "is a function" >> "$tmpfile" | 72 | type $1 | grep -v "is a function" >> "$tmpfile" |
| 72 | echo "$@" >> "$tmpfile" | 73 | echo "$@" >> "$tmpfile" |
| 73 | 74 | ||
