diff options
| author | EuAndreh <eu@euandre.org> | 2021-02-20 20:34:00 -0300 |
|---|---|---|
| committer | EuAndreh <eu@euandre.org> | 2021-02-20 20:34:00 -0300 |
| commit | 250117393a0503f66bb5a10cd0199f8748d32cda (patch) | |
| tree | 49482cd011eedf257eac3589d115b24132fb77d0 /aux | |
| parent | Add minimalistic notifications with xmobar (diff) | |
| download | dotfiles-250117393a0503f66bb5a10cd0199f8748d32cda.tar.gz dotfiles-250117393a0503f66bb5a10cd0199f8748d32cda.tar.xz | |
fake-symlinks: aux/workflow/: Support tags in TODOs.md
Diffstat (limited to 'aux')
| -rwxr-xr-x | aux/workflow/TODOs.sh | 11 | ||||
| -rw-r--r-- | aux/workflow/style.css | 10 |
2 files changed, 17 insertions, 4 deletions
diff --git a/aux/workflow/TODOs.sh b/aux/workflow/TODOs.sh index 5dbc7616..00fef6f7 100755 --- a/aux/workflow/TODOs.sh +++ b/aux/workflow/TODOs.sh @@ -7,10 +7,15 @@ export PROJECT_UC="$1" export PROJECT="$2" export MAILING_LIST="$3" -REGEX='s/^## (TODO|DOING|WAITING|MEETING|INACTIVE|NEXT|CANCELLED|DONE) (.*) \{#(.*?)\}$/## <a href="#\3"><span class="\1">\1<\/span> \2<\/a>\n<span class="header-anchor" id="\3">#\3<\/span>\n/' +TODOS_REGEX='s/^## (TODO|DOING|WAITING|MEETING|INACTIVE|NEXT|CANCELLED|DONE) (.*) \{#(.*?)\}$/## <a href="#\3"><span class="\1">\1<\/span> \2<\/a>\n<span class="header-anchor" id="\3">#\3<\/span>\n/' -envsubst < aux/workflow/preamble.md | \ - printf '%s\n\n%s' "$(cat -)" "$(perl -pe "$REGEX" TODOs.md)" | \ +TAGS_REGEX='s/tag:([\w-]+)/<span class="tag">\1<\/span>/g' + +envsubst < aux/workflow/preamble.md | \ + printf '%s\n\n%s' \ + "$(cat -)" \ + "$(perl -pe "$TODOS_REGEX" TODOs.md | \ + perl -pe "$TAGS_REGEX")" | \ pandoc --toc \ --highlight-style pygments \ --toc-depth=2 \ diff --git a/aux/workflow/style.css b/aux/workflow/style.css index ac0144c5..d7935d0e 100644 --- a/aux/workflow/style.css +++ b/aux/workflow/style.css @@ -3,10 +3,18 @@ background-color: #ccc; } - span.header-anchor { + div.header-anchor { opacity: 0.5; } + span.tag { + font-family: monospace; + font-size: 70%; + background-color: lightgray; + padding: 3px; + border-radius: 5px; + } + /* Replicate colors from: https://git.euandreh.xyz/dotfiles/tree/spacemacs.el?id=fcd9f9c4ef399d45d54927382dc1cdde251ebb0a#n866 |
