mirror of
https://github.com/Ahwxorg/nixos-config.git
synced 2025-12-04 15:00:13 +01:00
feat: now open just neovim if no note is selected
This commit is contained in:
parent
e2e0bfa3b7
commit
9a74ba2ed4
1 changed files with 8 additions and 2 deletions
|
|
@ -13,6 +13,12 @@ cd "$NOTEDIR" || mkdir -p "$NOTEDIR" && cd "$NOTEDIR" || echo 'Error with moving
|
|||
echo "Check if connected to internet and pull changes from Git"
|
||||
ping -c1 github.com >/dev/null && notify-send "$(git pull)" # Pull most recent changes, be sure to not create conficts...
|
||||
|
||||
kitty -e nvim "$CHOSEN" # Finally open chosen note
|
||||
if [ "$CHOSEN" ]; then
|
||||
kitty -e nvim "$CHOSEN" # Finally open chosen note
|
||||
|
||||
git add "$CHOSEN" && git commit -m "chore: updates (auto)" && git push && notify-send "Changes pushed"
|
||||
else
|
||||
cd "$NOTEDIR" || exit 1
|
||||
kitty -e nvim
|
||||
fi
|
||||
|
||||
git add "$CHOSEN" && git commit -m "chore: updates (auto)" && git push && notify-send "Changes pushed"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue