diff options
author | Tom Ryder <tom@sanctum.geek.nz> | 2017-06-25 14:29:08 +1200 |
---|---|---|
committer | Tom Ryder <tom@sanctum.geek.nz> | 2017-06-25 14:30:11 +1200 |
commit | 49baf42cff246ae9bc96baab66b9233003eb9bb0 (patch) | |
tree | 5e750c97b58954497066f087bd4a35e6dfe85ed8 | |
parent | Remove deprecated keyserver options (diff) | |
download | dotfiles-49baf42cff246ae9bc96baab66b9233003eb9bb0.tar.gz dotfiles-49baf42cff246ae9bc96baab66b9233003eb9bb0.zip |
Add install-conf target
Allows you to have a ~/.dotfiles.conf specifying targets to run in
addition to `install`, e.g. `install-tmux` for applicable machines.
Won't document this one just yet.
-rw-r--r-- | ISSUES.markdown | 1 | ||||
-rw-r--r-- | Makefile | 3 | ||||
-rw-r--r-- | install/install-conf.sh | 10 |
3 files changed, 14 insertions, 0 deletions
diff --git a/ISSUES.markdown b/ISSUES.markdown index a69e07df..7dcaa770 100644 --- a/ISSUES.markdown +++ b/ISSUES.markdown @@ -23,3 +23,4 @@ Known issues my own stuff in there * Completion for custom functions e.g. `sd` should ideally respect `completion-ignore-case` setting +* Document `install-conf` target once I'm sure it's not a dumb idea @@ -315,6 +315,9 @@ install: install-bin \ install-readline \ install-vim +install-conf: + sh install/install-conf.sh + install-abook: mkdir -p -- $(HOME)/.abook cp -p -- abook/abookrc $(HOME)/.abook diff --git a/install/install-conf.sh b/install/install-conf.sh new file mode 100644 index 00000000..f50cde73 --- /dev/null +++ b/install/install-conf.sh @@ -0,0 +1,10 @@ +# Read extra targets from an optional ~/.dotfiles.conf file +if [ -e "$HOME"/.dotfiles.conf ] ; then + while read -r line ; do + case $line in + '#'*|'') ;; + *) set -- "$@" "$line" ;; + esac + done < "$HOME"/.dotfiles.conf +fi +make install "$@" |