diff options
author | Tom Ryder <tom@sanctum.geek.nz> | 2016-07-02 00:38:58 +1200 |
---|---|---|
committer | Tom Ryder <tom@sanctum.geek.nz> | 2016-07-02 00:38:58 +1200 |
commit | 610d194384cc9ab20431bf7212653d1679280c35 (patch) | |
tree | 47af090aebbaeac04ba7aaaddda88b383869d3f4 /bin | |
parent | Inline two lines in jfcd(1) (diff) | |
download | dotfiles-610d194384cc9ab20431bf7212653d1679280c35.tar.gz dotfiles-610d194384cc9ab20431bf7212653d1679280c35.zip |
Use terser arg noodling in tl(1)
Diffstat (limited to 'bin')
-rwxr-xr-x | bin/tl | 6 |
1 files changed, 2 insertions, 4 deletions
@@ -55,12 +55,10 @@ done shift "$((OPTIND-1))" # Need at least one tag -if ! (($#)) ; then - set /dev/stdin -fi +(($#)) || set /dev/stdin # Print each line as we read it, prepending the tags, separated by spaces -for file in "$@" ; do +for file ; do while IFS= read -r line ; do printf '%s%s%s\n' "$prefix" "$line" "$suffix" done < "$file" |