#!/usr/bin/bash set -euo pipefail app_name=notes if ! [[ -d $NOTES_DIR ]]; then notify-send --app-name="$app_name" --icon="accessories-text-editor" \ "Notes" "Could not open NOTES_DIR ($NOTES_DIR)" exit 1 fi cd "$NOTES_DIR" # Open the notes directory in foot, inside a persistent tmux session named # "notes" (stolen if it already exists), landing straight into an fzf picker exec foot --app-id="$app_name" -- \ tmux new-session -A -D -s "$app_name" -- \ nvim -c "NotesFindTags"