feat: add prompt to run zk after setup

master
Hektor Misplon 2025-05-09 22:16:27 +02:00
parent b58ff906e9
commit 2c7f44ce16
1 changed files with 7 additions and 1 deletions

View File

@ -4,5 +4,11 @@ if [ ! -d ~/.zk ]; then
echo "[zk] Setting up zettelkasten" echo "[zk] Setting up zettelkasten"
gh repo clone zk ~/.zk gh repo clone zk ~/.zk
else else
echo "[zk] Zettelkasten already set up. Use 'zk' to open it" echo "[zk] Zettelkasten already set up."
fi
read -p "Would you like to run 'zk' now? [y/N] " -n 1 -r
echo
if [[ $REPLY =~ ^[Yy]$ ]]; then
command -v zk >/dev/null 2>&1 && zk || echo "Error: 'zk' command not found in PATH"
fi fi