diff options
author | Tom Ryder <tom@sanctum.geek.nz> | 2017-06-03 01:09:25 +1200 |
---|---|---|
committer | Tom Ryder <tom@sanctum.geek.nz> | 2017-06-03 01:11:53 +1200 |
commit | 802729b618ad32986d640d34a085a819cf1752db (patch) | |
tree | 0820b042dd04953e907cfa99d430cb7022efc398 /bin | |
parent | Check presence of delimiters correctly (diff) | |
download | dotfiles-802729b618ad32986d640d34a085a819cf1752db.tar.gz dotfiles-802729b618ad32986d640d34a085a819cf1752db.zip |
Nicer toggle
Diffstat (limited to 'bin')
-rw-r--r-- | bin/mi5.awk | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/bin/mi5.awk b/bin/mi5.awk index 0bcc1930..2deec375 100644 --- a/bin/mi5.awk +++ b/bin/mi5.awk @@ -11,13 +11,11 @@ BEGIN { NR == 1 { printf "`" } # Blocks -NF == 1 && $1 == open && !mac { - mac = 1 +NF == 1 && $1 == open && !mac++ { printf "'" next } -NF == 1 && $1 == shut && mac { - mac = 0 +NF == 1 && $1 == shut && mac-- { printf "`" next } |