diff options
author | Leah Neukirchen <leah@vuxu.org> | 2019-08-15 18:13:20 +0200 |
---|---|---|
committer | Leah Neukirchen <leah@vuxu.org> | 2019-08-15 18:13:20 +0200 |
commit | 24911dea0afe29ddad3e8e295eb552a179f67db7 (patch) | |
tree | 6dbe17eb9460aa88da1aff492bd9509c186a83cb /ny2html | |
parent | ef64daa1b99d55688aa0f61f204fe54df3c3b48a (diff) | |
download | notyet-24911dea0afe29ddad3e8e295eb552a179f67db7.tar.gz notyet-24911dea0afe29ddad3e8e295eb552a179f67db7.tar.xz notyet-24911dea0afe29ddad3e8e295eb552a179f67db7.zip |
add * for waiting-for tasks
Diffstat (limited to 'ny2html')
-rwxr-xr-x | ny2html | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/ny2html b/ny2html index 8bf7279..e23a08f 100755 --- a/ny2html +++ b/ny2html @@ -10,7 +10,7 @@ def parse(io, filename=nil) todos = [Entry.new(-1, "/", "", [])] while line = io.gets - if line =~ /\A(?:\s*(?:#|\/\/)\s)?(\s*)([-xX?])\s+(.*)/ + if line =~ /\A(?:\s*(?:#|\/\/)\s)?(\s*)([-xX?*])\s+(.*)/ i, state, desc = $1.size, $2, $3 while i <= todos.last.depth todos.pop @@ -32,6 +32,7 @@ def render(e) when "x"; puts "☑" when "X"; puts "☒" when "?"; puts "?" # or 2370 + when "*"; puts "⊞" end puts e.desc.sub(/(^\s*)\(([A-Z])\)/) { $1 + "<b>" + [$2.ord + 9333].pack("U") + "</b>" }. gsub(/(?<=\s)@\w+/, '<i>\&</i>') |