Help with modifying a KM script please?
in The Archive
Hi, at some point I've taken a KM script from here (don't know who posted it, apologies) that inserts a link to existing notes.
It's coming up with two suggestions for each note - I suspect it's becuase in the folder there's a plist file for every .md note, because I used another app to access the folder and that's what it generates. Annoyingly.
The script is this - can this be modified to only show the one expected entry?
ls | sed -E -e 's/.[^.]*$//' -e 's!^([0-9]+)[[:space:]-]+(.+)!\2 [[\1]]!'
If not, it's no big deal, I've only accessed this folder with the other app to prepare for my exams and it's not part of my long term ZK approach, so I'll just start afresh once I'm through - but it would be really good. Thanks in advance.
Howdy, Stranger!
Comments
Do you mean like this?
This is a result of the plist shenanigans. This should work.
ls | sed -E -e 's/\..*$//' -e 's!^([0-9]+)[[:space:]-]+(.+)!\2 [[\1]]!' | sort -u
Will Simpson
My zettelkasten is for my ideas, not the ideas of others. I don’t want to waste my time tinkering with my ZK; I’d rather dive into the work itself. My peak cognition is behind me. One day soon, I will read my last book, write my last note, eat my last meal, and kiss my sweetie for the last time.
kestrelcreek.com
That's fantastic, thank you. I'll try that tomorrow.
:wq