My fish config
This commit is contained in:
13
functions/journal.fish
Normal file
13
functions/journal.fish
Normal file
@@ -0,0 +1,13 @@
|
||||
function journal
|
||||
if test -z $wiki
|
||||
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"
|
||||
if test -e "$wiki/journal/$(date +%Y/%m/%d).md"
|
||||
$NVIM +'execute "normal :WikiJournal\<cr>Go\<enter>\<esc>!!date +\\\\%R\<cr>I# \<c-o>o\<enter>"' +"norm G\$" -c 'startinsert';
|
||||
else
|
||||
$NVIM +'execute "normal :WikiJournal\<cr>!!date +\\\\%R\<cr>I# \<c-o>o\<enter>"' +"norm G\$" -c 'startinsert'
|
||||
end
|
||||
end
|
||||
Reference in New Issue
Block a user