dotfiles

Obligatory dotfiles repo
git clone git://git.danielmoch.com/dotfiles.git
Log | Files | Refs

commit 7d6d7752f9b590d7d5f44faee3fab9ed7ecd6c9c
parent ebca38128a4fa1c8d797ef0180998506d5e08b61
Author: Daniel Moch <daniel@danielmoch.com>
Date:   Tue,  6 Feb 2018 20:24:30 -0500

Add git hook to tar and stage dotfiles

Diffstat:
M.local/bin/my-init | 3++-
A.local/lib/dotfiles/pre-push | 7+++++++
2 files changed, 9 insertions(+), 1 deletion(-)

diff --git a/.local/bin/my-init b/.local/bin/my-init @@ -126,13 +126,14 @@ then unset vim_bundle_path fi +[ -d "$HOME/.dotfiles" ] && cp "$HOME/.local/lib/dotfiles/pre-push" "$HOME/.dotfiles/.git/hooks/" [ ! -d "$HOME/.local/var/log" ] && mkdir -p "$HOME/.local/var/log" [ ! -d "$HOME/.local/var/forecastio" ] && mkdir -p "$HOME/.local/var/forecastio" [ ! -d "$HOME/.vim/undo/" ] && mkdir -p "$HOME/.vim/undo" if [ ! -f "$HOME/._.djmoch" ] then - touch "$HOME/._.djmoch" + : > "$HOME/._.djmoch" chmod 000 "$HOME/._.djmoch" fi diff --git a/.local/lib/dotfiles/pre-push b/.local/lib/dotfiles/pre-push @@ -0,0 +1,7 @@ +#!/bin/sh +cd .dotfiles +tar czvf dotfiles.tar.gz `git ls master ..` +scp dotfiles.tar.gz dotcom:~ +ssh dotcom sudo update_dotfiles +rm dotfiles.tar.gz +exit 0