dotfiles

config files and scripts at HOME.
git clone git://git.ricketyspace.net/dotfiles.git
Log | Files | Refs

commit 372ebce80815faf09d2a32484023c396ad829649
parent 40705b2be035c6238058af8fbd89ebd0c5000ea4
Author: rsiddharth <s@ricketyspace.net>
Date:   Mon, 31 Oct 2016 22:40:40 +0000

Add.bin/annex-to

This script will replace `annex-jarl` and `annex-chum`.

Diffstat:
.bin/annex-to | 31+++++++++++++++++++++++++++++++
1 file changed, 31 insertions(+), 0 deletions(-)

diff --git a/.bin/annex-to b/.bin/annex-to @@ -0,0 +1,31 @@ +#!/bin/sh +# +# Copyright (C) 2016 rsiddharth <s@ricketyspace.net> +# +# This program is free software: you can redistribute it and/or +# modify it under the terms of the GNU General Public License as +# published by the Free Software Foundation, either version 3 of the +# License, or (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +# General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program (see COPYING). If not, see +# <http://www.gnu.org/licenses/>. + +# annex-to path +ANNEX_PATH=$1 + +if [ -d $ANNEX_PATH ]; then + echo 'annexing to' $ANNEX_PATH '...' + cd $ANNEX_PATH + git annex sync + git annex get --all + echo 'finished annexing to' $ANNEX_PATH +else + echo $ANNEX_PATH 'not found.' + exit 1 +fi