forked from victoriadrake/dotfiles
-
Notifications
You must be signed in to change notification settings - Fork 0
/
repos.list.home
executable file
·73 lines (62 loc) · 2.64 KB
/
repos.list.home
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
#!/bin/bash
# TODO: need to be able to optionally specify the location/name of the cloned repo (specifically for /dendron-workspace)
# TODO: need to make a "common" 'repo-install' between 'home' and 'work'
# list of git repos to clone
# list is defined by "<src> <dest>"
# NOTE: all SSH keys must be setup ahead of time for this script to work
DEV_DIR="${HOME}/dev"
## Joe's ORG Stuff
DENDRON_DIR="${HOME}/dendron"
org=( \
"[email protected]:joehays/dendron-workspace.git ${HOME}" \
"[email protected]:joehays/dendron.git ${DENDRON_DIR}" \
"[email protected]:joehays/org-joe.git ${DENDRON_DIR}/dependencies/github.com/joehays/org-joe" \
"[email protected]:joehays/org-scripture-power.git ${DENDRON_DIR}/dependencies/github.com/joehays/org-scripture-power" \
"[email protected]:joehays/org-tech.git ${DENDRON_DIR}/dependencies/github.com/joehays/org-tech"
#"[email protected]:joehays/dotfiles.git ${DEV_DIR}/dotfiles"
)
## utilities/tools
utils=( \
"[email protected]:VundleVim/Vundle.vim.git ${HOME}/.vim/bundle/Vundle.vim" \
)
## Qualitative Data Analytics
qual=( \
"[email protected]:ccbogel/QualCoder.git ${DEV_DIR}/qualcoder" \
"[email protected]:joehays/scripture-analytics.git ${DEV_DIR}/scripture-analytics"
)
## Markdown Scriptures
MDS_DIR="${DEV_DIR}/markdown-scriptures"
md_scriptures=( \
"[email protected]:wordtreefoundation/bomdb.git ${MDS_DIR}/bomdb" \
"[email protected]:amonrperes/lds-datahouse-api.git ${MDS_DIR}/lds-datahouse-api" \
"[email protected]:mdjasper/lds-scripture-nlp-query-parser.git ${MDS_DIR}/lds-scripture-nlp-query-parser" \
"[email protected]:awerkamp/markdown-scriptures-standard-works-church-of-jesus-christ.git ${MDS_DIR}/markdown-scriptures-standard-works-church-of-jesus-christ" \
"[email protected]:samuelbradshaw/python-scripture-scraper.git ${MDS_DIR}/python-scripture-scraper" \
"[email protected]:jlconlin/scripture2url.git ${MDS_DIR}/scripture2url" \
"[email protected]:digitalbias/scripture_extractor.git ${MDS_DIR}/scripture_extractor" \
)
## combine all repo lists...
repos=( \
"${org[@]}" \
"${utils[@]}" \
"${qual[@]}" \
"${md_scriptures[@]}"
)
## function to conditionally clone the repo (if it doesn't already exist at the destination)
function gitClone () {
list=("$@")
echo "len(list)=${#list[@]}"
for repo in "${list[@]}"
do
src="$(echo ${repo} | cut -d ' ' -f 1)"
dest="$(echo ${repo} | cut -d ' ' -f 2)"
if [[ -d "${dest}" ]]; then
echo "!!!!!! '${src}' is already cloned to '${dest}'"
else
echo ">>>>>> now cloning ${src}"
git clone ${src} ${dest}
fi
done
}
## Main script
gitClone "${repos[@]}"