-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathinstall.sh
737 lines (621 loc) · 25.7 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
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
#!/usr/bin/env bash
#####################################################################
# Some basics first
#
# Define colors
RED='\033[0;31m'
GREEN='\033[0;32m'
NC='\033[0m' # No Color
release=$(lsb_release -c -s)
# Check if the script is running under Ubuntu 18.04 Bionic Beaver
if [ "$release" != "focal" ] && [ "$release" != "jammy" ] ; then
>&2 echo -e "${RED}This script is made for Ubuntu 20.04/22.04${NC}"
exit 1
fi
# TODO removeme once it can be run
exit 42 # it's still WIP and not really ready to be executed from start to end
#####################################################################
#####################################################################
# Ubuntu Tweaks for Dell
# repo: https://github.com/JackHack96/dell-xps-9570-ubuntu-respin
if [ "$release" == "focal" ]; then
sudo bash -c "$(curl -fsSL https://raw.githubusercontent.com/JackHack96/dell-xps-9570-ubuntu-respin/master/xps-tweaks.sh)"
else
echo "https://raw.githubusercontent.com/JackHack96/dell-xps-9570-ubuntu-respin/master/xps-tweaks.sh does not support ubuntu 22.04"
fi
#####################################################################
#####################################################################
# Install Brave Browser
sudo apt install apt-transport-https curl
curl -s https://brave-browser-apt-release.s3.brave.com/brave-core.asc | sudo apt-key --keyring /etc/apt/trusted.gpg.d/brave-browser-release.gpg add -
echo "deb [arch=amd64] https://brave-browser-apt-release.s3.brave.com/ stable main" | sudo tee /etc/apt/sources.list.d/brave-browser-release.list
sudo apt update
sudo apt install brave-browser
# TODO restore configuration from backup (backup default config first located @ ~/.config/BraveSoftware/BraveBrowser)
# ~/.config/BraveSoftware/BraveBrowser
# TODO make brave default browser
# TODO quire app desktop shortcut
# open brave://apps/
# right click on Quire and add shortcuts
#####################################################################
#####################################################################
# Remove unneeded packages
sudo apt remove \
remmina \
ibus-table
# Manually remove games from Ubuntu Software (GNOME)
# TODO find out package names
# Remove preinstalled openjdk packages
if [ "$release" == "focal" ]; then
sudo apt remove openjdk-11-jre:amd64 openjdk-11-jre-headless:amd64
fi
# Clean up
sudo apt autoremove
# Remove snap packages
sudo snap remove vlc && rm -rf ~/snap/vlc # Remove VLC (will be installed with flatpak)
#####################################################################
#####################################################################
# Apt packages
# Right after install
sudo apt install \
git \
vim \
tmux \
python3 \
python3-pip \
python3-gpg \
fonts-powerline \
xsel \
xclip \
network-manager \
network-manager-gnome \
network-manager-openvpn-gnome \
network-manager-openconnect-gnome
# remove -gnome postfix on non-GNOME desktops
# for network-manager packages
# Misc apt packages
sudo apt install \
flameshot \
jq \
backintime-common \
backintime-qt
# php
if [ "$release" == "focal" ]; then
sudo apt install php7.4 php7.4-curl php7.4-xml
else
sudo apt install php8.1 php8.1-curl php8.1-xml
fi
# Fonts (fixes rendering of images)
# After installing should be able to see the dog symbol 🐕
# the slice of pizza symbol 🍕
# and thumbs-up symbol 👍
if [ "$release" == "focal" ]; then # the issue that I was solving by installing these packages does not seem to be repsent in 22.04
sudo apt install ttf-ancient-fonts ttf-ancient-fonts-symbola
fi
# Timeshift (backup utility)
sudo add-apt-repository -y ppa:teejee2008/ppa
sudo apt-get update
sudo apt-get install timeshift
# QBitTorrent (now installed with flatpak)
# sudo add-apt-repository ppa:qbittorrent-team/qbittorrent-stable
# sudo apt install qbittorrent
# Syncthing
curl -s https://syncthing.net/release-key.txt | sudo apt-key add -
echo "deb https://apt.syncthing.net/ syncthing stable" | sudo tee /etc/apt/sources.list.d/syncthing.list
sudo apt update
sudo apt install syncthing
#####################################################################
#####################################################################
# VPN
#####################################################################
#####################################################################
# Citrix
# download https://www.citrix.com/downloads/workspace-app/linux/workspace-app-for-linux-latest.html
# debian -> full packages -> Citrix Workspace app for Linux (x86_64)
sudo dpkg -i ~/Downloads/icaclient_19.12.0.19_amd64.deb
# fix ssl error
sudo ln -s /usr/share/ca-certificates/mozilla/* /opt/Citrix/ICAClient/keystore/cacerts
sudo c_rehash /opt/Citrix/ICAClient/keystore/cacerts
#####################################################################
#####################################################################
# Pip packages
pip3 install --user virtualenv
pip3 install --user virtualenvwrapper
pip3 install --user ansible
#####################################################################
#####################################################################
# Dotfiles
# repo: https://github.com/voku/dotfiles?files=1
cd ~ ; git clone https://github.com/voku/dotfiles.git; cd dotfiles
# Check aptitude packages installed from the first install script
cp ./firstInstallDebianBased.sh ./firstInstall.sh
vim ./firstInstall.sh
# Apply the following changes
# diff ./firstInstallDebianBased.sh ./firstInstall.sh
#50c50
#< mktemp \
#> `#mktemp` \
#75c75
#< libjpeg-progs \
#> `#libjpeg-progs` \
#84c84
#< locales \
#> `#locales` \
#86c86
#< localepurge \
#> `#localepurge` \
#119c119
#< ttf-freefont \
#> `#ttf-freefont` \
#123,128c123,128
#< ttf-liberation \
#< ttf-linux-libertine \
#< ttf-larabie-deco \
#< ttf-larabie-straight \
#< ttf-larabie-uncommon \
#< ttf-liberation \
#> `#ttf-liberation` \
#> `#ttf-linux-libertine` \
#> `#ttf-larabie-deco` \
#> `#ttf-larabie-straight` \
#> `#ttf-larabie-uncommon` \
#> `#ttf-liberation` \
#149c149
#< xpdf \
#> `#xpdf` \
#152,154c152,154
#< python \
#< python-pip \
#< python-dev \
#> python3 \
#> python3-pip \
#> python3-dev \
#156c156
#< python-pygments
#> `#python-pygments`
#169c169
#< ln -s /usr/bin/nodejs /usr/bin/node
#> #ln -s /usr/bin/nodejs /usr/bin/node
# Run for the first installation
sudo ./firstInstall.sh
# Copy dotfiles to home
./bootstrap.sh
# TODO configure using zsh for default Terminal app
# open Terminal -> Preferences -> Command -> 'Run custom command instead of my shell' -> Custom Command : /usr/bin/zsh
#####################################################################
#####################################################################
# Extra ZSH Plugins
######
# https://github.com/zsh-users/zsh-autosuggestions
git clone https://github.com/zsh-users/zsh-autosuggestions ~/.redpill/plugins/zsh-autosuggestions
# change color of the autosuggestions
# https://upload.wikimedia.org/wikipedia/commons/1/15/Xterm_256color_chart.svg
"ZSH_AUTOSUGGEST_HIGHLIGHT_STYLE=\"fg=#767676,underline\"" >> ~/.extra
######
# https://github.com/agkozak/zsh-z
git clone https://github.com/agkozak/zsh-z ~/.redpill/plugins/zsh-z
# enable plugin in '~/.config_dotfiles'
# fix autocompletion https://github.com/agkozak/zsh-z#complete_aliases
# vim /home/sergio/.redpill/lib/1_options.zsh
######
#####################################################################
#####################################################################
# Extra CLI tools
######
# delta https://github.com/dandavison/delta
# bat https://github.com/sharkdp/bat
# bat completion for zsh: mv /path/to/bat.zsh ~/.redpill/plugins/zsh-completions/src/_bat
# exa https://github.com/ogham/exa
# git-fuzzy https://github.com/bigH/git-fuzzy
# lazygit https://github.com/jesseduffield/lazygit/
######
##########
# gitwatch
# https://github.com/gitwatch/gitwatch#starting-on-boot
# add service for watching todo.txt after installing the tool (remember to change the executable path in the gitwatch@service)
# systemctl --user --now enable gitwatch@$(systemd-escape "'-r git@github.com:hilarious-ceviche/todoer.git' -b main $HOME/todoer/todo.txt").service
##########
#####################################################################
#####################################################################
# Tmux dotfiles
# repo: https://github.com/gpakosz/.tmux
mv ~/.tmux.conf ~/.tmux.conf.bak
cd ~ ; git clone https://github.com/gpakosz/.tmux.git
ln -s -f ~/.tmux/.tmux.conf
cp ~/.tmux/.tmux.conf.local ~/.
#####################################################################
#####################################################################
# Restore dotfiles configuration
cp /path/to/backup/home/sergio/dotfiles/startpage-nord.html ~/dotfiles/.
diff -ENwburq backup_dir original_dir # recurse diff files in dirs
# symlinks
ln -s ~/phabricator/arcanist/bin/arc ~/bin/arc
ln -s ~/phabricator/elhubdev/bin ~/bin/elhubdev
ln -s ~/Downloads /path/to/data/Downloads
#####################################################################
#####################################################################
# Install sdkman
# url: https://sdkman.io/
curl -s "https://get.sdkman.io?rcupdate=false" | bash
#####################################################################
#####################################################################
# Update java alternatives
sudo update-alternatives --install /usr/bin/java java /home/sergio/.sdkman/candidates/java/current/bin/java 9999
sudo update-alternatives --install /usr/bin/javac javac /home/sergio/.sdkman/candidates/java/current/bin/javac 9999
sudo update-alternatives --install /usr/bin/javadoc javadoc /home/sergio/.sdkman/candidates/java/current/bin/javadoc 9999
sudo update-alternatives --install /usr/bin/keytool keytool /home/sergio/.sdkman/candidates/java/current/bin/keytool 9999
sudo update-alternatives --install /usr/bin/orbd orbd /home/sergio/.sdkman/candidates/java/current/bin/orbd 9999
sudo update-alternatives --install /usr/bin/pack200 pack200 /home/sergio/.sdkman/candidates/java/current/bin/pack200 9999
# sudo update-alternatives --install /usr/bin/policytool policytool /home/sergio/.sdkman/candidates/java/current/bin/policytool 9999
sudo update-alternatives --install /usr/bin/rmid rmid /home/sergio/.sdkman/candidates/java/current/bin/rmid 9999
sudo update-alternatives --install /usr/bin/rmiregistry rmiregistry /home/sergio/.sdkman/candidates/java/current/bin/rmiregistry 9999
sudo update-alternatives --install /usr/bin/servertool servertool /home/sergio/.sdkman/candidates/java/current/bin/servertool 9999
sudo update-alternatives --install /usr/bin/tnameserv tnameserv /home/sergio/.sdkman/candidates/java/current/bin/tnameserv 9999
sudo update-alternatives --install /usr/bin/unpack200 unpack200 /home/sergio/.sdkman/candidates/java/current/bin/unpack200 9999
sudo update-alternatives --install /usr/bin/jjs jjs /home/sergio/.sdkman/candidates/java/current/bin/jjs 9999
sudo update-alternatives --install /usr/bin/javaws javaws /home/sergio/.sdkman/candidates/java/current/bin/javaws 9999
#TODO find out if there's an easier way to do this
# For example:
for file in ~/.sdkman/candidates/java/current/bin/*
do
if [ -x $file ]
then
filename=`basename $file`
sudo update-alternatives --install /usr/bin/$filename $filename $file 20000
sudo update-alternatives --set $filename $file
#echo $file $filename
fi
done
#####################################################################
#####################################################################
# Install NodeVersionManager
# git: https://github.com/nvm-sh/nvm
curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.35.3/install.sh | bash
# remove lines added to ~/.zshrc
#####################################################################
#####################################################################
# Install FZF
# git: https://github.com/junegunn/fzf
#####################################################################
#####################################################################
# Install Guake terminal
sudo apt install \
gir1.2-keybinder-3.0 \
gir1.2-notify-0.7 \
gir1.2-vte-2.91 \
libkeybinder-3.0-0 \
libutempter0 \
python3-setuptools \
python3-cairo \
python3-dbus \
python3-gi \
python3-pbr \
python3-pip \
python3 \
gir1.2-wnck-3.0 # fixes some dependency issue but not mentioned in the prerequisites
pip3 install --user guake
# TODO add desktop application for quick launch
# TODO settings
#####################################################################
#####################################################################
# Install Joplin
wget -O - https://raw.githubusercontent.com/laurent22/joplin/master/Joplin_install_and_update.sh | bash
# copy config and notes from backup to ~/.config/joplin-desktop
# TODO this can be automated once notes are encrypted
#####################################################################
#####################################################################
# Install typora
wget -qO - https://typora.io/linux/public-key.asc | sudo apt-key add -
# or use
# sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys BA300B7755AFCFAE
# add Typora's repository
sudo add-apt-repository 'deb https://typora.io/linux ./'
sudo apt update
# install typora
sudo apt install typora
#####################################################################
#####################################################################
# Change logrotate duration for apt and dpgk
sudo vim /etc/logrotate.d/apt
# change rotate from 12 (months) to any other value
sudo vim /etc/logrotate.d/dpkg
# same as above
#####################################################################
#####################################################################
# Battery saving options
#####################################################################
#####################################################################
# Install AppImage Launcher
# https://github.com/TheAssassin/AppImageLauncher/wiki/Install-on-Ubuntu-or-Debian
sudo add-apt-repository ppa:appimagelauncher-team/stable
sudo apt update
sudo apt install appimagelauncher
#####################################################################
#####################################################################
# Install AppImage applications
# KeePassXC https://keepassxc.org/download/
# PCloud https://www.pcloud.com/download-free-online-cloud-file-storage.html
# Cryptomator https://cryptomator.org/downloads/
# Wire https://wire.com/en/download/
#####################################################################
#####################################################################
# Install Software
# IntelliJ Toolbox
# copy /path/to/backup/.ideavimrc to ~/.ideavimrc
# copy /path/to/backup/.config/Jetbrains to ~/.config/Jetbrains
# copy /path/to/backup/.local/share/JetBrains to ~/.local/share/Jetbrains
# IntelliJ Idea
# Atom
# Dropbox
# DavMail Client
# url: http://davmail.sourceforge.net/download.html
# url: https://sourceforge.net/projects/davmail/files/
# Mozilla Firefox
# copy /path/to/backup/.mozilla to ~/.mozilla
# copy /path/to/backup/.thunderbird to ~/.thunderbird
# Mozilla Thunderbird
#####################################################################
#####################################################################
# Vagrant and VirtualBox
# Download vagrant deb image https://www.vagrantup.com/downloads
# can use a script to download
# and install with `sudo dpkg -i ~/Downloads/vagrant_.deb`
# using `apt install` is strongly discouraged by hashicorp
# VirtualBox latest downloads https://www.virtualbox.org/wiki/Downloads
# Or use apt, but looks like the version is slightly older
#####################################################################
#####################################################################
# Add to startup if necessary
# Cryptomator, KeePassXC, Dropbox, PCloud, JetBrains Toolbox,
#####################################################################
#####################################################################
# VPN connections
#####################################################################
#####################################################################
# Visuals / Desktop / Extensions
# Gnome Extensions
sudo apt install \
gnome-shell-extensions \
chrome-gnome-shell # to be able to use extensions.gnome.org
# https://extensions.gnome.org/extension/19/user-themes/ # needed for custom themes to work properly
# https://extensions.gnome.org/extension/1160/dash-to-panel/ # nice alternative to default dock
# Themes
# sweet theme: https://www.gnome-look.org/p/1253385/
# nord theme: https://www.gnome-look.org/p/1267246
# Conky
curl -sL -o /opt/conky-x86_64.AppImage \
$(curl -sL https://api.github.com/repos/brndnmtthws/conky/releases/latest | \
jq --raw-output '.assets[0] | .browser_download_url')
sudo chmod +x /opt/conky
# configs are in ~/.config/conky
#
# conky minimalis theme: https://www.gnome-look.org/p/1112273/#files-panel
# conky-orange-4k: https://gist.github.com/serpro69/0d7b7d109c7f70766b60ee0c20439e16
# conky-aureola: https://github.com/erikdubois/Aureola
# Plank dock
# https://github.com/ricotz/plank
sudo apt install plank
# config is in ~/.config/plank
#####################################################################
#####################################################################
# Disable Bluetooth
sudo systemctl disable bluetooth.service
sudo vim /etc/bluetooth/main.conf
#search for AutoEnable=true
#change to AutoEnable=false
sudo install -b -m 755 /dev/stdin /etc/rc.local << EOF
#!/bin/sh
/etc/init.d/bluetooth stop
rfkill block bluetooth
exit 0
EOF
# some extras are also done with tlp
#####################################################################
#####################################################################
# Disable lid actions
# Set logind.conf
sudo /etc/systemd/logind.conf
# HandleLidSwitch=ignore
# LidSwitchIgnoreInhibited=no
# Set UPower.conf
# Note: this might not be desirable, as it will keep laptop screen always on,
# even on closed lid
sudo /etc/UPower/UPower.conf
# IgnoreLid=true
sudo service upower restart
#####################################################################
#####################################################################
# Mounts
sudo mkdir /mnt/data
sudo tee -a /etc/fstab > /dev/null << EOF
# data partition from windows setup
UUID=CED8DBC8D8DBACC9 /mnt/data ntfs-3g auto,user,exec,utf8,uid=1000,gid=1000,rw 0 0
# RAM mount for Intellij Idea
#tmpfs /tmp/ramdisk tmpfs noexec,defaults,noatime,size=2048M,x-gvfs-show,mode=1777 0 0
tmpfs /tmp/ramdisk tmpfs defaults,noatime,size=2048M,x-gvfs-show,mode=1777 0 0
EOF
sudo mount -a
#####################################################################
#####################################################################
# swappiness
echo "vm.swappiness=10" | sudo tee -a /etc/sysctl.conf > /dev/null
#####################################################################
#####################################################################
# Tmp dirs for RAM mount
sudo install -b -m 755 /dev/stdin /usr/lib/tmpfiles.d/radmisk.tmp.conf << EOF
# This file will create some temporary directories
# on the ramdisk mount partition.
#Type Path Mode UID GID Age Argument
d /tmp/ramdisk/intellij/caches 0777 root root - -
d /tmp/ramdisk/intellij/index 0777 root root - -
d /tmp/ramdisk/chrome 0777 root root - -
d /tmp/ramdisk/intellij/system 0777 root root - -
EOF
#####################################################################
#####################################################################
# Remove lowlatency kernel packages
uname -r # if contains lowlatency
# search if others than below are present
# sudo apt remove -lowlatency<TAB>
sudo apt remove --purge \
linux-image-5.4.0-24-lowlatency \
linux-image-5.4.0-25-lowlatency \
linux-modules-5.4.0-24-lowlatency \
linux-modules-5.4.0-25-lowlatency \
linux-modules-nvidia-440-5.4.0-24-lowlatency \
linux-modules-nvidia-440-5.4.0-25-lowlatency \
linux-modules-nvidia-440-lowlatency-hwe-20.04
sudo apt install \
linux-modules-nvidia-440-5.4.0-25-generic \
linux-modules-nvidia-440-generic-hwe-20.04 \
shutdown -r now
#####################################################################
#####################################################################
# Extras
rmdir ~/Downloads && ln -s /mnt/data/Downloads ~/Downloads
#####################################################################
#####################################################################
# sqldeveloper
sudo cp -r /path/to/backup/opt/sqldeveloper /opt/.
# or download and unarchive
cp -r /path/to/backup/home/sergio/.sqldeveloper ~/.
#####################################################################
#####################################################################
# SoapUI
sudo cp -r /path/to/backup/opt/SoapUI-5.5.0 /opt/.
# or download and unarchive
cp -r /path/to/backup/home/sergio/.sqldeveloper ~/.
#####################################################################
#####################################################################
# Flatpack
# https://flatpak.org/setup/Ubuntu/
sudo apt install flatpak
# Add flathub repo
flatpak remote-add --if-not-exists flathub https://flathub.org/repo/flathub.flatpakrepo
#####################################################################
#####################################################################
# Flatpack Packages
########
# Peek #
# https://github.com/phw/peek#flatpak
flatpak install flathub com.uploadedlobster.peek
########
###############
# LibreOffice #
flatpak install flathub org.libreoffice.LibreOffice
###############
###########
# DBeaver #
# (2020.08.13) flatpack is now supported:
flatpak install flathub io.dbeaver.DBeaverCommunity
# download latest release https://github.com/dbeaver/dbeaver/releases
# unarchive to /opt
# cp /opt/dbeaver.desktop ~/.local/share/applications/.
# vim ~/.local/share/applications/dbeaver.desktop
# modify paths (use sed instead)
# Alternatively use one of the repositories
#https://dbeaver.io/download/?start&os=linux&arch=x86_64&dist=deb
# Debian repository:
# wget -O - https://dbeaver.io/debs/dbeaver.gpg.key | sudo apt-key add -
# echo "deb https://dbeaver.io/debs/dbeaver-ce /" | sudo tee /etc/apt/sources.list.d/dbeaver.list
# sudo apt-get update && sudo apt-get install dbeaver-ce
#
# Ubuntu PPA:
# You can use PPA repository to easily install/upgrade DBeaver on Debian Linuxes. Mostly it is the same as regular Debian repo but it is hosted on Launchpad.
# sudo add-apt-repository ppa:serge-rider/dbeaver-ce
# sudo apt-get update
# sudo apt-get install dbeaver-ce
# Vim support
#Standalone dbeaver can install some eclipse plugins.
#So I'm using vrapper as vim keybindings on dbeaver.
#
#Help -> Install Software
#Add vrapper repository http://vrapper.sourceforge.net/update-site/stable
#Install
#Restart dbeaver
###########
#######
# VLC #
flatpak install flathub org.videolan.VLC
# NB! config is in /home/sergio/.var/app/org.videolan.VLC/
#######
#########
# Sleek #
# https://github.com/ransome1/sleek#get-sleek-from-flathub
flatpak install flathub com.github.ransome1.sleek
#########
###########
# Calibre #
# https://github.com/ransome1/sleek#get-sleek-from-flathub
flatpak install flathub com.calibre_ebook.calibre
###########
############
# Obsidian #
flatpak install flathub md.obsidian.Obsidian
############
############
# Bookworm #
flatpak install flathub com.github.babluboy.bookworm
############
###########
# Foliate #
flatpak install flathub com.github.johnfactotum.Foliate
###########
########
# Anki #
flatpak install flathub net.ankiweb.Anki
########
###############
# qBittorrent #
flatpak install flathub org.qbittorrent.qBittorrent
###############
#####################################################################
#####################################################################
# System Settings
# Settings -> Removable Media -> Never prompt or start programs on media insertion
#####################################################################
#####################################################################
# Cronies
#
# hist size notification
# 0 12 * * * /home/sergio/bin/cronies/notify-on-hist-size.sh
#
# periodic local applications' configs backups
# 0 18 6 * * zip -r $HOME/bak/Brave-Browser.bak.$(date +'\%Y\%m\%d').zip /home/sergio/.config/BraveSoftware/Brave-Browser >$HOME/bak/brave-browser-backup.log.$(date +'\%Y\%m\%d') 2>&1
# 0 18 7 * * zip -r $HOME/bak/thunderbird.bak.$(date +'\%Y\%m\%d').zip /home/sergio/.thunderbird >$HOME/bak/thunderbird-backup.log.$(date +'\%Y\%m\%d') 2>&1
# 0 18 8 * * zip -r $HOME/bak/jetbrains.bak.$(date +'\%Y\%m\%d').zip /home/sergio/.config/JetBrains /home/sergio/.local/share/JetBrains >$HOME/bak/jetbrains-backup.log.$(date +'\%Y\%m\%d') 2>&1
#
#
### Notify on current history size
mkdir ~/bin/cronies && cd ~/bin/cronies
touch notify-on-hist-size.sh
tee -a ./notify-on-hist-size.sh > /dev/null << EOF
#!/bin/bash
userid=$(id -u)
DBUS_SESSION_BUS_ADDRESS="unix:path=/run/user/$userid/bus"
export DBUS_SESSION_BUS_ADDRESS
if [[ $(wc -l ~/.zsh_history | cut -d ' ' -f1) > 15000 ]]; then
notify-send -u critical 'HISTFILESIZE Limit' 'Hist file size is above 15000 LOC'
fi
EOF
#
# add crontab calling the script daily at 1200
# 0 12 * * * /home/sergio/bin/cronies/notify-on-hist-size.sh
###
#
#####################################################################
#####################################################################
# Fonts #
cd $(mktemp -d)
# IMB-Plex
wget -O plex.zip https://github.com/IBM/plex/releases/latest/download/TrueType.zip
unzip plex.zip
mv TrueType ~/.fonts/.
# Jetbrains Mono
wget -o jetbrains.zip https://github.com/JetBrains/JetBrainsMono/releases/download/v2.242/JetBrainsMono-2.242.zip
unzip jetbrains.zip
mkdir ~/.local/share/fonts
mv fonts/* ~/.local/share/fonts/.
# copy humor-sans font from backup
fc-cache -f -v
#####################################################################