From: Edward Delaporte Date: Mon, 6 Jul 2026 12:58:20 +0000 (-0500) Subject: Tighten up core help X-Git-Url: https://us-delaporte.pagekite.me/gitweb/dotfiles.git/commitdiff_plain/b5c4353d4750fd3e38da3230830ab781f61c2b97?ds=inline Tighten up core help --- diff --git a/bin/dot b/bin/dot index a08b732..aa633ec 100755 --- a/bin/dot +++ b/bin/dot @@ -4,10 +4,6 @@ ANSIBLE="$ENVS/ansible/bin/ansible-playbook" read -d '' HELP << EOF dot - a (mostly) one script dotfiles manager -1. Install this file on your path -2. Clone your (or my) 'dotfiles' repository to ~/dotfiles -3. Run 'dot help' to get started. - Copyright 2026 Edward Delaporte V Licensed under AGPLv3 and later. @@ -18,22 +14,53 @@ dot link FILE updates ~/dot.HOSTNAME.yaml to include a symlink from ~/dotfiles/files/FILE to ~/.FILE +dot check + check setup against ~/backup/dot.HOSTNAME.yaml + +dot apply + apply config in ~/backup/dot.HOSTNAME.yaml + +dot help FEATURE + setup - more information on setup + all - additional features +EOF + +read -d '' SETUP_HELP << EOF +## Setup + +1. Install this file on your path +2. Clone your (or my) 'dotfiles' repository to ~/dotfiles +3. Run 'dot help' to get started. + +EOF + + +read -d '' EXTRA_HELP << EOF + dot install SCRIPT updates ~/dot.HOSTNAME.yaml to run ~/dotfiles/SCRIPT.sh if it has not yet been run creates ~/dot/SCRIPT.installed after SCRIPT has been run -dot check - check setup against ~/dot.HOSTNAME.yaml - -dot apply - apply config in ~/dot.HOSTNAME.yaml EOF + if [ ! -n "$1" ] || [ "$1" == "help" ]; then echo "$HELP" fi +if [ "$1" == "help" ] && [ "$2" == "all" ]; then + echo "" + echo "$EXTRA_HELP" + echo "" + echo "$SETUP_HELP" +fi +if [ "$1" == "help" ] && [ "$2" == "setup" ]; then + echo "" + echo "$SETUP_HELP" +fi + # set -v +# TASKFILE="$HOME/backup/dot.$HOSTNAME.yaml" LINKFILES="$HOME/dotfiles/files"