remove a few needless bashisms...

Note: "able" still needs bash but it's an easy fix if you need to use it
on a bash-challenged machine and care enough
This commit is contained in:
Sitaram Chamarty 2010-06-01 16:27:33 +05:30
parent faf1629fd8
commit 805050a129
7 changed files with 18 additions and 18 deletions

View file

@ -1,4 +1,4 @@
#!/bin/bash
#!/bin/sh
# please make sure this file is NOT chmod +x
@ -11,7 +11,7 @@ get_rights_and_owner() {
# set shell variables as needed
owner=${ans#* }
rights=${ans% *}
[[ $rights =~ C ]] && perm_create=yes || perm_create=
[[ $rights =~ R ]] && perm_read=yes || perm_read=
[[ $rights =~ W ]] && perm_write=yes || perm_write=
echo $rights | grep C >/dev/null 2>&1 && perm_create=yes || perm_create=
echo $rights | grep R >/dev/null 2>&1 && perm_read=yes || perm_read=
echo $rights | grep W >/dev/null 2>&1 && perm_write=yes || perm_write=
}