diff options
author | Leon Rische <leon.rische@me.com> | 2020-11-02 14:03:32 +0100 |
---|---|---|
committer | Leon Rische <leon.rische@me.com> | 2020-11-02 14:03:32 +0100 |
commit | 730f8461002d6562856c8f636c1b5cd7d8a2c638 (patch) | |
tree | ba36acc536f5789bff5772e740d595e78bb84773 | |
parent | 1c593dad698305b93c418191dbe689ff8c45a391 (diff) |
Better tag regex
-rw-r--r-- | awk/index.awk | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/awk/index.awk b/awk/index.awk index 6caf408..29c982c 100644 --- a/awk/index.awk +++ b/awk/index.awk @@ -69,7 +69,7 @@ match($0, /^(\*+)[ \t]+(.*)$/, a) { # this only guarantees that there is at least one tab/space # between the headline text and the tags. # TODO: Do this in a single match - if (match(title, /^(.*)[ \t]+(:([a-zA-Z0-9_@#%]+:)+)$/, b) != 0) { + if (match(title, /^(.*)[ \t]+(:([[:alnum:]_@#%]+:)+)$/, b) != 0) { title = b[1]; # remove trailing tabs/spaces sub(/[ \t]*$/, "", title); |