diff options
author | Case Duckworth | 2022-08-13 19:33:44 -0500 |
---|---|---|
committer | Case Duckworth | 2022-08-13 19:33:44 -0500 |
commit | ec12e69af6ba6527e987e0ce0e1505688eb2e0ba (patch) | |
tree | 14cc43388769d0b951e855fe665de62d59dc204d | |
parent | Try to correct RAW trailing newline bug (diff) | |
download | ht-ec12e69af6ba6527e987e0ce0e1505688eb2e0ba.tar.gz ht-ec12e69af6ba6527e987e0ce0e1505688eb2e0ba.zip |
Still trying to fix bug ....
I really need to not push every time I think I'm fixing something ...
-rwxr-xr-x | ht.awk | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/ht.awk b/ht.awk index 68fb558..a03c8be 100755 --- a/ht.awk +++ b/ht.awk | |||
@@ -34,8 +34,11 @@ $0 ~ CONFIG["raw_delim"] { | |||
34 | buflush() | 34 | buflush() |
35 | bufpush(CONFIG["raw_beg"], -1) | 35 | bufpush(CONFIG["raw_beg"], -1) |
36 | } else { | 36 | } else { |
37 | if (substr(BUFFER, length(BUFFER)) == "\n") { | ||
38 | BUFFER = substr(BUFFER, 1, length(BUFFER) - 1) | ||
39 | } | ||
37 | bufpush(CONFIG["raw_end"], -1) | 40 | bufpush(CONFIG["raw_end"], -1) |
38 | printf "%s", BUFFER | 41 | print BUFFER |
39 | BUFFER = "" | 42 | BUFFER = "" |
40 | } | 43 | } |
41 | next | 44 | next |