dotfiles/.local/bin/scripts/roam

5 lines
241 B
Plaintext
Raw Normal View History

2021-10-08 10:28:22 +00:00
#!/bin/sh -e
# Move roam files into subfolders
cd $DATA/2-standards/notes
2021-10-15 11:43:54 +00:00
find . -mindepth 1 -type d -printf '%f\n' | while read dir; do grep -l --directories=skip "#+filetags: :$dir" * | xargs --verbose --no-run-if-empty mv -t "$dir"; done