play with reading many args

This commit is contained in:
Thomas Levine 2016-04-10 17:04:12 +00:00
parent 22e9f57f0f
commit a084577951

8
urchin
View File

@ -226,6 +226,14 @@ plural () {
fi fi
} }
read_many() {
if delimiter="${1}" && shift; then
while test "${#}" -gt 0; do
echo "while read -d '${delimiter}'; do"
done
fi
}
has_shebang_line() { has_shebang_line() {
head -n 1 "${1}" | grep -v '^#!/bin/sh$' | grep -q '^#!' head -n 1 "${1}" | grep -v '^#!/bin/sh$' | grep -q '^#!'
} }