summaryrefslogtreecommitdiff
path: root/bin/common/toush
diff options
context:
space:
mode:
Diffstat (limited to 'bin/common/toush')
-rwxr-xr-xbin/common/toush14
1 files changed, 14 insertions, 0 deletions
diff --git a/bin/common/toush b/bin/common/toush
new file mode 100755
index 0000000..dd675b9
--- /dev/null
+++ b/bin/common/toush
@@ -0,0 +1,14 @@
+#!/bin/sh
+# fork of
+# https://codeberg.org/futxlii/bin/toush :)
+
+shebang='#!/bin/sh'
+
+usage() { >&2 printf 'Usage: %s' "${0##*/}"; exit 1 ;}
+
+[ "$1" ] || usage
+while [ "$1" ]; do
+ [ -f "$1" ] && usage
+ printf '%s\n\n' "$shebang" > "$1" && chmod +x "$1"
+ shift
+done