annotate bin/shebang_args_or_input @ 8683:ebcf284eeb4f

<oerjan> ` mv she* bin
author HackBot
date Sun, 03 Jul 2016 23:27:00 +0000
parents shebang_args_or_input@62de6fa2c08b
children b09f2c5c49dd
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
8682
62de6fa2c08b <oerjan> fetch http://oerjan.nvg.org/shebang_args_or_input
HackBot
parents:
diff changeset
1 #!/bin/bash
62de6fa2c08b <oerjan> fetch http://oerjan.nvg.org/shebang_args_or_input
HackBot
parents:
diff changeset
2 interp="$1"; script="$2"; shift 2; if [ "$#" -gt 0 ]; then printf '%s\n' "$*"; else cat; fi | "$interp" "$script"