-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbootstrap.sh
executable file
·138 lines (120 loc) · 2.22 KB
/
bootstrap.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
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
#!/usr/bin/env bash
# install missing packaging
cd "$(dirname "${BASH_SOURCE}")";
#git pull origin master;
function install_packages {
declare -a packages=(
"git"
"git-cola"
"gitg"
"gitk"
"meld"
"curl"
"cmake"
"stow"
"vim"
"tmux"
"zsh"
"silversearcher-ag"
"numix-icon-theme"
"guake"
"ranger"
"caca-utils"
"highlight"
"atool"
"w3m"
"poppler-utils"
"mediainfo"
"filezilla"
"kicad"
"openscad"
"blender"
"pdfmod"
"texstudio"
"texlive-latex-extra"
"pip"
"vlc"
"calibre"
"pcb2gcode"
"entr"
"xdotool"
"htop"
"build-essence"
"python3-dev"
"nodejs"
"npm"
"ctag"
"translate-shell"
"avrdude"
"meshlab"
# npm install -g http-server
)
# ack
# cloc
# ddgr
# wmctrl
# gawk
# git clone https://github.com/tmux-plugins/tpm ~/.tmux/plugins/tpm
# compizconfig-settings-manager
cat -n Dotfiles/bootstrap.sh | sort -k2 -u | sort -nk1,1 | cut -f2-
## now loop through the above array
for i in "${packages[@]}"
do
echo "================================================================================"
echo "====================================== $i ======================================"
echo "================================================================================"
sudo apt install -y "$i"
done
}
#function restore_symulink() {
# #function_body
# "bcnc"
#}
function install_theme() {
upt-add-repository ppa:numix/ppa
sudo apt-get update
sudo apt-get install numix-icon-theme-circle
git clone https://github.com/chriskempson/base16-shell.git ~/.config/base16-shell
}
function intstall_vim(){
stow vim
vim '+PlugUpdate' '+PlugClean!' '+PlugUpdate' '+qall'
}
function restore_dotfiles() {
#function_body
cd dotfiles
declare -a resorte_config=(
"tmux"
"zsh"
"ranger"
)
for i in "${resorte_config[@]}"
do
stow $i
done
}
# function make_folders() {
# cd
# mkdir Documents/Fonts
# mkdir Software
# mkdir Projects
# mkdir Snippets
# mkdir Screenshots
# }
function doIt() {
install_packages
# restore_dotfiles
# intstall_vim
# install_theme
# make_folders
}
if [ "$1" == "--force" -o "$1" == "-f" ]; then
doIt;
else
read -p "This may overwrite existing files in your home directory. Are you sure? (y/n) " -n 1;
echo "";
if [[ $REPLY =~ ^[Yy]$ ]]; then
doIt;
fi;
fi;
unset doIt;