-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathinstall.sh
331 lines (252 loc) · 13.4 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
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
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
clear
# VARIBALES DEFINED
CONFIG=/home/$USER/.config/myPopConfig
EXTENSIONS=/home/$USER/.local/share/gnome-shell/extensions
# CREATING REQUIRED DIRECTORY
mkdir -p $CONFIG
if [[ ! -f "$CONFIG/.PROMPTED" ]]
then
if zenity --question --no-wrap --title='myPopConfig' --text='Do you want to Default Apps ?\n\nThis will install VSCODE + OnlyOffice + Calculus + Notion (Unofficial) + WhatsApp for Linux (Unofficial)'
then
touch $CONFIG/.DEFAULT
fi
if zenity --question --title='myPopConfig' --text='Do you want Laptop Specific Settings?'
then
touch $CONFIG/.LAPTOP
fi
touch $CONFIG/.PROMPTED
fi
# Setting-up the BASE SYSTEM
if [[ ! -f "$CONFIG/.BaseSystem1" ]]
then
# Disable Unwanted Extenstions
gnome-extensions disable [email protected]
gnome-extensions disable [email protected]
gnome-extensions disable [email protected]
gnome-extensions disable [email protected]
# Removing Show Applications, Show Launcher & Show Workspaces
sudo rm /usr/share/applications/pop-cosmic-applications.desktop
sudo rm /usr/share/applications/pop-cosmic-workspaces.desktop
sudo rm /usr/share/applications/pop-cosmic-launcher.desktop
# Install Pre-Req
# Repo for nala
echo "deb [arch=amd64,arm64,armhf] http://deb.volian.org/volian/ scar main" | sudo tee /etc/apt/sources.list.d/volian-archive-scar-unstable.list
wget -qO - https://deb.volian.org/volian/scar.key | sudo tee /etc/apt/trusted.gpg.d/volian-archive-scar-unstable.gpg > /dev/null
sudo apt update
sudo apt install nala git curl -y
# APT : Preferences, Repos, & Mirrors
# Repo for VS CODE
wget -qO- https://packages.microsoft.com/keys/microsoft.asc | gpg --dearmor > packages.microsoft.gpg
sudo install -D -o root -g root -m 644 packages.microsoft.gpg /etc/apt/keyrings/packages.microsoft.gpg
sudo sh -c 'echo "deb [arch=amd64,arm64,armhf signed-by=/etc/apt/keyrings/packages.microsoft.gpg] https://packages.microsoft.com/repos/code stable main" > /etc/apt/sources.list.d/vscode.list'
rm -f packages.microsoft.gpg
# Repo for JETBRAINS (UNOFFICIAL) Source : https://github.com/JonasGroeger/jetbrains-ppa/
curl -s https://s3.eu-central-1.amazonaws.com/jetbrains-ppa/0xA6E8698A.pub.asc | gpg --dearmor | sudo tee /usr/share/keyrings/jetbrains-ppa-archive-keyring.gpg > /dev/null
echo "deb [signed-by=/usr/share/keyrings/jetbrains-ppa-archive-keyring.gpg] http://jetbrains-ppa.s3-website.eu-central-1.amazonaws.com any main" | sudo tee /etc/apt/sources.list.d/jetbrains-ppa.list > /dev/null
# Repo for Grub Customizer
sudo add-apt-repository ppa:danielrichter2007/grub-customizer -y
# Repo for Flatpak
sudo add-apt-repository ppa:flatpak/stable -y
# Repo for Mozilla Firefox
sudo add-apt-repository ppa:mozillateam/ppa -y
# Repo for Android Studio
sudo add-apt-repository ppa:maarten-fonville/android-studio -y
# APT mirrors
sudo nala fetch --auto -y
# Clean Up
sudo nala remove --purge libreoffice* gnome-weather gnome-calendar gnome-contacts totem geary seahorse popsicle popsicle-gtk baobab gnome-user-docs* ubuntu-docs yelp simple-scan -y
sudo nala clean
sudo nala autoremove -y
# Flatpak Setup
sudo flatpak remote-add --if-not-exists flathub https://flathub.org/repo/flathub.flatpakrepo
# Upgating Existing Packages
sudo nala upgrade -y
sudo flatpak update -y
# Base Apps
sudo nala install firefox vlc grub-customizer grub-efi preload htop gnome-tweaks ubuntu-restricted-extras -y
sudo flatpak install flathub com.mattjakeman.ExtensionManager -y
# Laptop Specific Packages & Config
if [[ -f "$CONFIG/.LAPTOP" ]]
then
sudo nala install tlp tlp-rdw -y
sudo tlp start
sudo systemctl enable tlp
sudo systemstl start tlp
fi
# Install Extensions
mkdir .extensions
cd .extensions
wget https://extensions.gnome.org/extension-data/blur-my-shellaunetx.v43.shell-extension.zip
wget https://extensions.gnome.org/extension-data/date-menu-formattermarcinjakubowski.github.com.v7.shell-extension.zip
wget https://extensions.gnome.org/extension-data/just-perfection-desktopjust-perfection.v22.shell-extension.zip
wget https://extensions.gnome.org/extension-data/theme-switcherfthx.v5.shell-extension.zip
wget https://extensions.gnome.org/extension-data/lockkeysvaina.lt.v47.shell-extension.zip
wget https://extensions.gnome.org/extension-data/drive-menugnome-shell-extensions.gcampax.github.com.v51.shell-extension.zip
wget https://extensions.gnome.org/extension-data/user-themegnome-shell-extensions.gcampax.github.com.v49.shell-extension.zip
if [[ -f "$CONFIG/.LAPTOP" ]]
then
wget https://extensions.gnome.org/extension-data/x11gesturesjoseexposito.github.io.v14.shell-extension.zip
fi
unzip blur-my-shellaunetx.v43.shell-extension.zip -d ./blur-my-shell@aunetx/
unzip date-menu-formattermarcinjakubowski.github.com.v7.shell-extension.zip -d ./[email protected]/
unzip just-perfection-desktopjust-perfection.v22.shell-extension.zip -d ./just-perfection-desktop@just-perfection/
unzip theme-switcherfthx.v5.shell-extension.zip -d ./theme-switcher@fthx/
unzip lockkeysvaina.lt.v47.shell-extension.zip -d ./[email protected]/
unzip drive-menugnome-shell-extensions.gcampax.github.com.v51.shell-extension.zip -d ./[email protected]/
unzip user-themegnome-shell-extensions.gcampax.github.com.v49.shell-extension.zip -d ./[email protected]/
if [[ -f "$CONFIG/.LAPTOP" ]]
then
unzip x11gesturesjoseexposito.github.io.v14.shell-extension.zip -d ./[email protected]/
fi
rm blur-my-shellaunetx.v43.shell-extension.zip
rm date-menu-formattermarcinjakubowski.github.com.v7.shell-extension.zip
rm just-perfection-desktopjust-perfection.v22.shell-extension.zip
rm theme-switcherfthx.v5.shell-extension.zip
rm lockkeysvaina.lt.v47.shell-extension.zip
rm drive-menugnome-shell-extensions.gcampax.github.com.v51.shell-extension.zip
rm user-themegnome-shell-extensions.gcampax.github.com.v49.shell-extension.zip
if [[ -f "$CONFIG/.LAPTOP" ]]
then
rm x11gesturesjoseexposito.github.io.v14.shell-extension.zip
fi
mkdir -p $EXTENSIONS
cp * $EXTENSIONS -r
cd ..
rm -r ./.extensions
# GRUB CUSTOMIZER
sudo grub-install
sudo cp /boot/grub/x86_64-efi/grub.efi /boot/efi/EFI/pop/grubx64.efi
sudo mkdir -p "/boot/grub/themes/"
sudo cp -a ./grubthemes/* /boot/grub/themes/
sudo cp /etc/default/grub ./
sudo rm /etc/default/grub
sed -i '/GRUB_GFXMODE=/d' ./grub
sed -i '/GRUB_TIMEOUT=/d' ./grub
sed -i '/GRUB_TIMEOUT_STYLE=/d' ./grub
sed -i '/GRUB_THEME=/d' ./grub
echo 'GRUB_GFXMODE="auto"' >> ./grub
echo 'GRUB_TIMEOUT="10"' >> ./grub
echo 'GRUB_TIMEOUT_STYLE="menu"' >> ./grub
echo 'GRUB_THEME="/boot/grub/themes/Sleek-Dark/theme.txt"' >> ./grub
sudo mv ./grub /etc/default/
sudo update-grub
clear
echo "+-------------------+"
echo "| Grub Customizer |"
echo "+-------------------+"
echo ""
echo "Step 1 : In \"List Configuration\" tab, Configure the Boot Enteries."
echo ""
echo "Step 2 : In \"Appearance Settings\" tab, Set a Custom Resolution & Select a Theme."
echo ""
echo " +------+"
echo "Step 3 : Press | Save | then EXIT Grub Customizer Pop-up Window !!...."
echo " +------+"
sudo grub-customizer >> null
clear
rm null
touch $CONFIG/.BaseSystem1
zenity --info --title='myPopConfig' --text='This system needs RESTART. Press [OK] to RESTART. After the System restarts, please Re-Execute this Script...'
reboot
fi
if [[ ! -f "$CONFIG/.BaseSystem2" ]]
then
# Enabling Extensions
gnome-extensions enable blur-my-shell@aunetx
gnome-extensions enable [email protected]
gnome-extensions enable [email protected]
gnome-extensions enable just-perfection-desktop@just-perfection
gnome-extensions enable [email protected]
gnome-extensions enable theme-switcher@fthx
gnome-extensions enable [email protected]
if [[ -f "$CONFIG/.LAPTOP" ]]
then
gnome-extensions enable [email protected]
fi
# Tweaking Extensions
gsettings --schemadir $EXTENSIONS/[email protected]/schemas/ set org.gnome.shell.extensions.lockkeys style 'capslock'
gsettings --schemadir $EXTENSIONS/[email protected]/schemas/ set org.gnome.shell.extensions.date-menu-formatter pattern 'EEEE, MMMM dd | hh : mm a'
if [[ -f "$CONFIG/.LAPTOP" ]]
then
gsettings --schemadir $EXTENSIONS/[email protected]/schemas/ set org.gnome.shell.extensions.x11gestures swipe-fingers 4
fi
gsettings --schemadir $EXTENSIONS/just-perfection-desktop@just-perfection/schemas/ set org.gnome.shell.extensions.just-perfection theme true
gsettings --schemadir $EXTENSIONS/just-perfection-desktop@just-perfection/schemas/ set org.gnome.shell.extensions.just-perfection activities-button false
gsettings --schemadir $EXTENSIONS/just-perfection-desktop@just-perfection/schemas/ set org.gnome.shell.extensions.just-perfection events-button false
gsettings --schemadir $EXTENSIONS/just-perfection-desktop@just-perfection/schemas/ set org.gnome.shell.extensions.just-perfection world-clock false
gsettings --schemadir $EXTENSIONS/just-perfection-desktop@just-perfection/schemas/ set org.gnome.shell.extensions.just-perfection weather false
gsettings --schemadir $EXTENSIONS/just-perfection-desktop@just-perfection/schemas/ set org.gnome.shell.extensions.just-perfection window-demands-attention-focus true
gsettings --schemadir $EXTENSIONS/just-perfection-desktop@just-perfection/schemas/ set org.gnome.shell.extensions.just-perfection clock-menu-position 1
gsettings --schemadir $EXTENSIONS/just-perfection-desktop@just-perfection/schemas/ set org.gnome.shell.extensions.just-perfection clock-menu-position-offset 8
gsettings --schemadir $EXTENSIONS/just-perfection-desktop@just-perfection/schemas/ set org.gnome.shell.extensions.just-perfection notification-banner-position 2
gsettings --schemadir $EXTENSIONS/just-perfection-desktop@just-perfection/schemas/ set org.gnome.shell.extensions.just-perfection osd-position 5
gsettings set org.gnome.shell.extensions.ding show-trash true
gsettings set org.gnome.shell.extensions.ding show-volumes true
# Tweaking Trackpad Settings
if [[ -f "$CONFIG/.LAPTOP" ]]
then
gsettings set org.gnome.desktop.peripherals.touchpad natural-scroll true
gsettings set org.gnome.desktop.peripherals.touchpad click-method 'areas'
fi
touch $CONFIG/.BaseSystem2
killall -3 gnome-shell
fi
if [[ -f "$CONFIG/.DEFAULT" ]]
then
sudo nala install code p7zip-rar -y
sudo flatpak install flathub com.github.carlos157oliveira.Calculus org.onlyoffice.desktopeditors com.github.eneshecan.WhatsAppForLinux -y
wget https://raw.githubusercontent.com/puneetsl/lotion/master/setup.sh
chmod +x ./setup.sh
./setup.sh native
rm ./setup.sh
else
# Optional Apps
touch .AdditionalAPPS.sh
#APT
if zenity --question --title='myPopConfig' --text='Install VS CODE ?'
then
echo "sudo nala install code -y" >> .AdditionalAPPS.sh
fi
if zenity --question --title='myPopConfig' --text='Install Android Studio ?'
then
echo "sudo nala install android-studio -y" >> .AdditionalAPPS.sh
fi
if zenity --question --title='myPopConfig' --text='Install PyCharm (Community) ?'
then
echo "sudo nala install pycharm-community -y" >> .AdditionalAPPS.sh
fi
if zenity --question --title='myPopConfig' --text='Install DataSpell ?'
then
echo "sudo nala install dataspell -y" >> .AdditionalAPPS.sh
fi
if zenity --question --title='myPopConfig' --text='Install IntelliJ IDEA (Community) ?'
then
echo "sudo nala install intellij-idea-community -y" >> .AdditionalAPPS.sh
fi
# Flatpak
if zenity --question --title='myPopConfig' --text='Install OnlyOffice ?'
then
echo "sudo flatpak install flathub org.onlyoffice.desktopeditors -y" >> .AdditionalAPPS.sh
fi
if zenity --question --title='myPopConfig' --text='Install Calculus ?'
then
echo "sudo flatpak install flathub com.github.carlos157oliveira.Calculus -y" >> .AdditionalAPPS.sh
fi
if zenity --question --title='myPopConfig' --text='Install WhatsApp for Linux (Unofficial) ?'
then
echo "sudo flatpak install flathub com.github.eneshecan.WhatsAppForLinux -y" >> .AdditionalAPPS.sh
fi
# Source Build
if zenity --question --title='Ubuntu Spinner' --text='Install Notion (Unofficial) ?'
then
echo "sudo apt install p7zip-rar -y" >> .AdditionalAPPS.sh
echo "wget https://raw.githubusercontent.com/puneetsl/lotion/master/setup.sh" >> .AdditionalAPPS.sh
echo "chmod +x ./setup.sh" >> .AdditionalAPPS.sh
echo "./setup.sh native" >> .AdditionalAPPS.sh
echo "rm ./setup.sh" >> .AdditionalAPPS.sh
fi
chmod +x .AdditionalAPPS.sh
./.AdditionalAPPS.sh
rm ./.AdditionalAPPS.sh
dconf write /org/gnome/shell/favorite-apps "['firefox.desktop', 'org.gnome.Nautilus.desktop', 'org.gnome.Terminal.desktop', 'io.elementary.appcenter.desktop', 'vlc.desktop', 'code.desktop', 'android-studio.desktop', 'pycharm-community.desktop', 'dataspell.desktop', 'intellij-idea-community.desktop', 'Notion_native.desktop', 'org.onlyoffice.desktopeditors.desktop', 'com.github.eneshecan.WhatsAppForLinux.desktop']"
fi