aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--.topography3
-rw-r--r--README.md3
-rw-r--r--completion/_auto.zsh23
3 files changed, 29 insertions, 0 deletions
diff --git a/.topography b/.topography
new file mode 100644
index 0000000..3eeb413
--- /dev/null
+++ b/.topography
@@ -0,0 +1,3 @@
+$$ export PREFIX=/usr/local
+auto. #-> $PREFIX/bin
+completion/_*.zsh #-> $PREFIX/share/zsh/site-functions/
diff --git a/README.md b/README.md
index 1a10548..5a29f5e 100644
--- a/README.md
+++ b/README.md
@@ -34,3 +34,6 @@ ability to uninstall and install using just one line.
> [!Important]
> The `::` option is currently only supported on voidlinux, archlinux, and
> debian. If you would like to expand compatibility send [me](mailto:me@zacharyscheiman.com) a patch.
+## Installing
+Incase you wish to install this script on your computer a .topography file has
+been provided, to install simply run `./auto. -i`
diff --git a/completion/_auto.zsh b/completion/_auto.zsh
new file mode 100644
index 0000000..24875b8
--- /dev/null
+++ b/completion/_auto.zsh
@@ -0,0 +1,23 @@
+#compdef auto.
+
+_arguments \
+ '1:flag:->flags' \
+ '*:: :->args'
+
+case "$state" in
+ flags)
+ local -a opts
+ opts=(
+ '-t:Topography file'
+ '-i:Install dotfiles specified in the .topography file'
+ '-u:Uninstall dotfiles specified in the .topography file'
+ '-b:Exit at first error'
+ '-h:Show help text'
+ )
+ _describe 'flags' opts
+ ;;
+ args)
+ case $line[1] in
+ -t) _files ;;
+ esac
+esac