-
Notifications
You must be signed in to change notification settings - Fork 0
/
install.sh
executable file
·58 lines (46 loc) · 1.06 KB
/
install.sh
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
#!/bin/bash
set -eo pipefail
cd $(dirname $0)
os=unknown
cpu=unknown
repo=$(cd $(dirname $0) && pwd)
force=0
if [[ $1 == "force" || $1 == "--force" ]]; then
force=1
fi
if [[ $OSTYPE == "linux-"* ]]; then
os=linux
if [[ $(uname -a | awk '{ print $(NF-1) }') == "x86_64"* ]]; then
cpu=x86
else
cpu=arm
fi
elif [[ $OSTYPE == "darwin"* ]]; then
os=mac
if [[ $(uname -a | awk '{ print $(NF) }') == "arm"* ]]; then
cpu=arm
else
cpu=x86
fi
else
echo 1>&2 "Cannot install on this OS: ${OSTYPE}"
exit 2
fi
echo 1>&2 "**"
echo 1>&2 "** Install"
echo 1>&2 "** os: $os cpu: $cpu repo: $repo"
echo 1>&2 "**"
# source our profile so basic paths are setup
. ${repo}/bash_init $os $cpu $repo
${repo}/setup_dots.sh $os $cpu $repo
if [[ ${os} == "mac" ]]; then
${repo}/setup_brew.sh $repo $force
fi
${repo}/setup_bash.sh $os $cpu $repo
${repo}/setup_elixir.sh $force
${repo}/setup_shfmt.sh $force
${repo}/setup_rust.sh $force
${repo}/setup_git_lfs.sh
${repo}/setup_hub.sh $force
${repo}/setup_gpg.sh $os $cpu $repo
${repo}/setup_vim.sh $repo $force