diff options
author | Tom Ryder <tom@sanctum.geek.nz> | 2017-11-03 13:46:30 +1300 |
---|---|---|
committer | Tom Ryder <tom@sanctum.geek.nz> | 2017-11-03 13:46:30 +1300 |
commit | cd8e9cc27f7dd9d360b64f4a34b8c2d048f42e45 (patch) | |
tree | 5e95d601ee957685dc99de1339c2f1a999102f9a /bin/su2d.awk | |
parent | Merge branch 'feature/rm-stray-vim' into develop (diff) | |
download | dotfiles-cd8e9cc27f7dd9d360b64f4a34b8c2d048f42e45.tar.gz dotfiles-cd8e9cc27f7dd9d360b64f4a34b8c2d048f42e45.zip |
Apply simpler method for sd2u(1df) and su2d(1df)
This method is shorter, easier to read, and more idiomatic.
Diffstat (limited to 'bin/su2d.awk')
-rw-r--r-- | bin/su2d.awk | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/bin/su2d.awk b/bin/su2d.awk index 34a8c5ae..5a8eabaf 100644 --- a/bin/su2d.awk +++ b/bin/su2d.awk @@ -1,3 +1,3 @@ -# Convert UNIX line endings to DOS ones -!/\r$/ { $0 = $0 "\r" } -{ print } +# Convert stream UNIX line endings to DOS ones +BEGIN { ORS = "\r\n" } +1 |