1
0
Fork 0
mirror of https://github.com/correl/dotfiles.git synced 2024-12-20 12:56:07 +00:00
dotfiles/recipes/git

25 lines
459 B
Bash

#!/bin/bash
# Description: The Git version control system
set -e
case $_PLATFORM in
darwin)
_recipe brew
_brew git
;;
*)
_recipe _apt
_ppa git-core/ppa
_apt git
;;
esac
function _git {
local repo=$1
local dest=$2
if ! test -d "$dest"; then
_run "[git] Clone $repo to $dest" git clone --recursive $1 $2
else
echo "[git] $dest already exists, skipping."
fi
}