From 2333ad2feabbfca53d84cab3ffe2d95a50f52fe5 Mon Sep 17 00:00:00 2001 From: Segcolt Date: Mon, 9 Feb 2026 22:34:38 -0300 Subject: [PATCH] Add more stuff for journal --- functions/journal.fish | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-) diff --git a/functions/journal.fish b/functions/journal.fish index 1c4d395..ec03313 100644 --- a/functions/journal.fish +++ b/functions/journal.fish @@ -3,11 +3,19 @@ function journal echo "Por favor, define a variável \$wiki com o caminho da wiki." exit 5 end - set -x NVIM_APPNAME nvim.bak - set NVIM "$wiki/journal/nvim.appimage" + # set -x NVIM_APPNAME nvim.bak + # set NVIM "$wiki/journal/nvim.appimage" + + cd $wiki/journal + + git pull + set NVIM nvim if test -e "$wiki/journal/$(date +%Y/%m/%d).md" - $NVIM +'execute "normal :WikiJournal\Go\\!!date +\\\\%R\I# \o\"' +"norm G\$" -c 'startinsert'; + $NVIM +'set spell' +'execute "normal :WikiJournal\Go\\!!date +\\\\%R\I# \o\"' +"norm G\$" -c 'startinsert'; else - $NVIM +'execute "normal :WikiJournal\!!date +\\\\%R\I# \o\"' +"norm G\$" -c 'startinsert' + $NVIM +'set spell' +'execute "normal :WikiJournal\!!date +\\\\%R\I# \o\"' +"norm G\$" -c 'startinsert' end + git add . + git commit -m "More entries" + git push end