From 563c858d140b2854bbb130caacb44cfed81ad837 Mon Sep 17 00:00:00 2001 From: filip <“filip.rabiega@gmail.com”> Date: Sat, 8 Nov 2025 10:04:44 +0100 Subject: notesplain pipes into zathura and no es --- notesplain | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) (limited to 'notesplain') diff --git a/notesplain b/notesplain index c69b903..3249258 100755 --- a/notesplain +++ b/notesplain @@ -1,5 +1,9 @@ #!/bin/sh -dir="$HOME/.obsidian" -file="$(ls -l "$dir" | awk '{print $9}' | sed 's/.md//g' | dmenu -l 30)" -[ -n "$file" ] && batcat "$dir/$file.md" +dir="$OBSIDIAN_HOME" +file="$(ls -1 "$dir" | sed 's/\.md$//' | dmenu -l 30 -p 'Select note:')" + +if [ -n "$file" ]; then + tmpfile="$(mktemp /tmp/"$file"_XXXXXXXX.pdf)" + pandoc "$dir/$file.md" -o "$tmpfile" && zathura "$tmpfile" & +fi -- cgit v1.2.3