feat(journal): remove manual sync & let editFile do it

This commit is contained in:
ayo 2026-06-26 11:10:17 +02:00
parent 41b0f389f3
commit f8c10bd7d6
2 changed files with 3 additions and 10 deletions

View file

@ -1,4 +1,4 @@
#! /usr/bin/bash
#! /usr/bin/env bash
# Load config & functions
. ${HOME}/ayo.conf
@ -37,20 +37,14 @@ function createEntry() {
echo $date_heading > "$full_path"
fi
# Open in editor
if [ "$typora_flag" = true ]; then
typora "$full_path" > /dev/null 2>/dev/null
else
editFile "$full_path"
fi
editFile "$full_path"
} || {
# Report; TODO: write log
echo ">>> " $full_path
}
}
notesSync
if [ "$1" = "append" ]; then
{
read -p "Add thought: " thought
@ -69,4 +63,3 @@ elif [ "$1" = "copy" ] || [ "$1" = "c" ]; then
else
createEntry
fi
notesSync

View file

@ -1,4 +1,4 @@
#!/usr/bin/bash
#!/usr/bin/env bash
# Load config
. ${HOME}/ayo.conf