diff options
author | Raymaekers Luca <raymaekers.luca@gmail.com> | 2024-10-30 00:50:16 +0100 |
---|---|---|
committer | Raymaekers Luca <raymaekers.luca@gmail.com> | 2024-10-30 00:50:16 +0100 |
commit | 15bc38edec39279f26969ca4b67126f6e544b831 (patch) | |
tree | c500f84a07c04acce18035b7635e93a2f710f162 /bin/extra/notes_index | |
parent | 0e5e622952fe51588f1537e621c63cbe4a91c136 (diff) |
checkpoint
Diffstat (limited to 'bin/extra/notes_index')
-rwxr-xr-x | bin/extra/notes_index | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/bin/extra/notes_index b/bin/extra/notes_index index da5c6cf..28942cb 100755 --- a/bin/extra/notes_index +++ b/bin/extra/notes_index @@ -21,7 +21,7 @@ do -name 'index.md' \ -printf '%f ' \ -exec grep '^# ' -m1 {} \; | - sed 's/\(.\+\.md\) # \(.\+\)/- [\2](\1)/' | + sed 's/\(.\+\.md\) # \(.\+\)/- [\2][\1]/' | sort -t '[' -k 2 -n >> index.md if [ "$(find . -mindepth 2 -maxdepth 2 -type f -name '*.md' | wc -l)" -gt 0 ] @@ -32,7 +32,7 @@ do -maxdepth 1 \ -type d \ -not -name '.*'\ - -printf '- [%f](%f/index.md)\n' | + -printf '- [%f][%f/index.md]\n' | sort -t '[' -k 2 >> index.md fi |