Compare commits

19 Commits

Author SHA1 Message Date
a6e0696e31 Fixed postman 2022-07-05 20:50:48 +08:00
f61f09b83f Git updated 2022-07-05 17:05:34 +08:00
6bb9442c43 Small updates 2022-07-05 10:53:41 +08:00
c54e71d28c Rustdesk updated 2022-07-05 10:52:27 +08:00
8d64efba39 Postman fixed and updated 2022-07-05 10:51:43 +08:00
cc2ab13310 Lamp pack updated 2022-07-05 10:51:32 +08:00
113c1df71b New qt5, flameshot pack draft 2022-07-05 10:51:17 +08:00
24f30e8eff New papirus 2022-07-05 10:50:54 +08:00
bcb1111a0a Zsh and omz as pack (updated) 2022-07-05 10:50:35 +08:00
3fa1a4d09d New libreoffice script 2022-07-05 10:50:07 +08:00
6c11b5d76d Removed libreoffice and shit from apt 2022-07-05 10:49:39 +08:00
82559869fc Small fixes + WTFPLv2 2022-07-04 23:53:39 +08:00
4677b84a29 Initial docker sandbox 2022-07-04 23:25:31 +08:00
7008ec36b7 Apache fix 2022-07-04 23:24:43 +08:00
f2d41885af Composer cleanup 2022-07-04 23:24:27 +08:00
9972fc6d9d Updated chrome 2022-07-04 22:23:44 +08:00
f7ef85aad9 Updated apache2 2022-07-04 22:22:57 +08:00
3043a41365 Sort in apt 2022-07-04 22:22:37 +08:00
47c1e6d40b Fixed gen-makefile 2022-07-04 22:22:05 +08:00
23 changed files with 362 additions and 186 deletions

4
.dockerignore Normal file
View File

@@ -0,0 +1,4 @@
.git
.gitignore
.dockerignore
README.md

27
Dockerfile Normal file
View File

@@ -0,0 +1,27 @@
FROM ubuntu:22.04
RUN apt update && \
apt -y install \
apt-transport-https \
apt-utils \
bsdmainutils \
curl \
dialog \
grep \
make \
man \
sudo \
wget
RUN adduser ivan \
--quiet \
--home=/home/ivan \
--ingroup=sudo \
--disabled-password \
--disabled-login
COPY ./ /home/ivan/my-env
RUN echo "ivan ALL=(ALL) NOPASSWD:ALL" >> /etc/sudoers
USER ivan
WORKDIR /home/ivan/my-env

13
LICENSE Normal file
View File

@@ -0,0 +1,13 @@
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
Version 2, December 2004
Copyright (C) 2022 Антон Аксенов <anthonyaxenov@gmail.com>
Everyone is permitted to copy and distribute verbatim or modified
copies of this license document, and changing it is allowed as long
as the name is changed.
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
0. You just DO WHAT THE FUCK YOU WANT TO.

View File

@@ -1,7 +1,14 @@
# Autogenerated at 04.07.2022 22:11 using ./gen-makefile.sh
# Autogenerated at 05.07.2022 10:52 using ./gen-makefile
##lamp: Apache + php + mariadb
##flameshot: [TODO] [PACK] qt5 + flameshot from source
flameshot: qt5 flameshot-build
##lamp: [PACK] Apache + php + mariadb
lamp: apache php mariadb
##omz: [PACK] zsh + omz + powerline10k + MesloLGS fonts
omz: zsh omz-clean
##apache: Install apache2 (latest)
apache:
./install/apache
@@ -30,6 +37,10 @@ droidcam:
droidcam-obs:
./install/droidcam-obs
##flameshot-build: [TODO] Build flameshot from src (latest)
flameshot-build:
./install/flameshot-build
##git: Install git (latest)
git:
./install/git
@@ -46,6 +57,10 @@ grubc:
kde-appmenu:
./install/kde-appmenu
##libreoffice: Install libreoffice
libreoffice:
./install/libreoffice
##lite-xl: Install lite-xl v2.0.5 (draft)
lite-xl:
./install/lite-xl
@@ -58,6 +73,14 @@ mariadb:
nodejs:
./install/nodejs
##omz-clean: Install omz (latest) + powerline10k + MesloLGS fonts
omz-clean:
./install/omz-clean
##papirus: Install papirus-icon-theme (latest)
papirus:
./install/papirus
##pgsql: Install postgresql (latest) and php-pgsql (if php is installed)
pgsql:
./install/pgsql
@@ -70,7 +93,11 @@ php:
postman:
./install/postman
##rustdesk: Install rustdesk v1.1.8 (deb)
##qt5: Install qt5
qt5:
./install/qt5
##rustdesk: Install rustdesk client v1.1.9 (deb)
rustdesk:
./install/rustdesk
@@ -98,7 +125,7 @@ wine:
zint:
./install/zint
##zsh: Install zsh + omz (latest)
##zsh: Install vanilla zsh
zsh:
./install/zsh
@@ -109,6 +136,6 @@ help: Makefile
@echo "Available goals:"
@sed -n 's/^##//p' $< | column -t -s ':' | sed -e "s/^/\t/"
##<goal>_: Same as 'cat ./install/<goal>.sh'
##<goal>_: Same as 'cat ./install/<goal>'
%_:
@cat ./install/$*.sh
@cat ./install/$*

View File

@@ -4,11 +4,14 @@
## Requirements
* Ubuntu >= 20.04 (not tested with version < 20)
* `bash`, `zsh` or other `sh`-compatible shell
* `make` (optional but recommended)
* `wget` (necessary for some scripts)
* `git` (necessary for some scripts)
If some dependecies are missed for some of these scripts it is enougth to run `./install/apt` in most cases.
## Usage
### Clone this repo (recommended)
@@ -23,33 +26,37 @@ wget -qO - https://git.axenov.dev/anthony/my-env/archive/master.tar.gz | tar -zx
# switch to repo dir
cd my-env
# generate fresh ./Makefile and get full list of `make` goals
./gen-makefile
# get full list of `make` goals
make help
# generate new ./Makefile and get full list of `make` goals
./gen-makefile.sh
```
> I do not recommend to run `make` without arguments since then ALL goals will be started in their order.
>
> Use `make help` to look around.
### Selective straightforward installation
```shell
# from remote file
wget -qO - https://git.axenov.dev/anthony/my-env/raw/branch/master/install/apt.sh | bash
wget -qO - https://git.axenov.dev/anthony/my-env/raw/branch/master/install/apt | bash
# from locally cloned repo
./install/apt.sh
./install/apt
```
## How to add a new software script?
1. Create new `./install/*.sh` script.
1. Create new `./install/*` script.
At the beggining of a file you must write these two lines:
```shell
#!/bin/bash
##makedesc: Your description for Makefile
```
2. Test your script
3. Run `./gen-makefile.sh` to generate new `./Makefile`
3. Run `./gen-makefile` to generate new `./Makefile`
## How to create packs?
@@ -72,3 +79,36 @@ mypackY: goalA goalB
where:
* `mypack*` is the pack name
* `goal*` are script names in `./install`
## Testing in docker (not recommended)
> Note that this is almost useless way to test since you'll meet errors in many cases because dockerized OS is not fully-functional and will never be.
>
> You can use docker to test something **really simple**, e.g. to check general script steps or install cli tools.
>
> In other cases you need virtualized Ubuntu instead of dockerized one, so I strongly recommend you to use [VirtualBox](https://www.virtualbox.org/wiki/Downloads) or your host machine.
```shell
# switch to repo dir
cd my-env
# build and run container
docker build -t myenv . && docker run -it myenv
# or oneliner
docker run -it $(docker build -q .)
```
Now you can play around with scripts.
## TODO
* build: [flameshot](https://github.com/flameshot-org/flameshot#compilation)
* build: [rustdesk](https://github.com/rustdesk/rustdesk#build)
* [JB mono](https://www.jetbrains.com/ru-ru/lp/mono/#how-to-install) ([2](https://fonts.google.com/specimen/JetBrains+Mono))
* update scripts (when possible)
* uninstall scripts (when possible)
## License
[WTFPLv2](LICENSE)

View File

@@ -4,6 +4,7 @@ echo -e "# Autogenerated at $(date +'%d.%m.%Y %H:%M') using ${BASH_SOURCE[0]}\n"
for file in ./packs/*; do
cat ${file} >> Makefile
echo >> Makefile
done;
for file in ./install/*; do
@@ -20,14 +21,13 @@ help: Makefile
@echo "Usage:"
@echo "\tmake <goal>\n"
@echo "Available goals:"
@sed -n 's/^##//p' $< | column -t -s ':' | sed -e "s/^/\t/"
@sed -n 's/^##//p' \$< | column -t -s ':' | sed -e "s/^/\t/"
##<goal>_: Same as 'cat ./install/<goal>.sh'
##<goal>_: Same as 'cat ./install/<goal>'
%_:
@cat ./install/\$*.sh
@cat ./install/\$*
EOF
echo "New ./Makefile has been generated!"
echo "Old one has been saved as ./Makefile.bak"
echo

View File

@@ -7,6 +7,6 @@ echo "Installing apache2..."
echo "==============================================="
echo
sudo apt install -y --autoremove apache2
sudo service apache2 restart
apache2 -v
sudo apt install -y --autoremove apache2 && \
sudo systemctl restart apache2 && \
apache2 -v

View File

@@ -7,54 +7,50 @@ echo "Installing software from apt..."
echo "==============================================="
echo
sudo apt update && sudo apt upgrade -y --autoremove
sudo apt install -y --autoremove \
sudo apt update && \
sudo apt upgrade -y --autoremove
sudo apt install -y \
alien \
apt-transport-https \
ca-certificates \
curl \
make \
cmake \
dialog \
build-essential \
software-properties-common \
libaio1 \
libssl-dev \
libghc-zlib-dev \
libcurl4-gnutls-dev \
libexpat1-dev \
ca-certificates \
cmake \
curl \
dconf-editor \
default-jdk \
dialog \
gettext \
gnupg \
ubuntu-restricted-extras \
unzip \
mc \
htop \
nano \
neofetch \
default-jdk \
terminator \
dconf-editor \
alien \
meld \
vlc \
gparted \
hardinfo \
libreoffice \
pulseeffects \
lsp-plugins \
htop \
libaio1 \
libcurl4-gnutls-dev \
libexpat1-dev \
libghc-zlib-dev \
libssl-dev \
lsb-release \
lsp-plugins \
make \
mc \
meld \
nano \
neofetch \
net-tools \
nmap \
p7zip-full \
sqlitebrowser
pulseeffects \
software-properties-common \
sqlitebrowser \
terminator \
ubuntu-restricted-extras \
unzip \
vlc
# earlyoom \
# etckeeper \
# geoclue-2.0 \
# gnome-software \
# minder \
# redshift \
# redshift-gtk \
# nodejs \
# compiz \
# compizconfig-settings-manager \
# earlyoom \
# etckeeper \
# deepin-screenshot \
# geoclue-2.0 \
# at
# redshift-gtk

View File

@@ -9,7 +9,6 @@ echo
# https://t.me/axenov_blog/251
# sudo snap install chromium
wget "https://dl.google.com/linux/direct/google-chrome-stable_current_amd64.deb" -O /tmp/google-chrome-stable_current_amd64.deb
sudo dpkg -i /tmp/google-chrome-stable_current_amd64.deb
rm /tmp/google-chrome-stable_current_amd64.deb
wget "https://dl.google.com/linux/direct/google-chrome-stable_current_amd64.deb" -O /tmp/google-chrome-stable_current_amd64.deb && \
sudo dpkg -i /tmp/google-chrome-stable_current_amd64.deb && \
rm /tmp/google-chrome-stable_current_amd64.deb

View File

@@ -11,46 +11,31 @@ installed() {
command -v "$1" >/dev/null 2>&1
}
if installed "php"; then
if installed "composer"; then
echo "WARNING: You already have composer installed - removing to install actual version"
!installed "php" && echo "WARNING: You need to have php installed"
if installed "composer"; then
echo "WARNING: Removing current composer to install its actual version"
sudo apt remove -y --autoremove composer
sudo rm -f /bin/composer
sudo rm -f /usr/bin/composer
sudo rm -f /usr/local/bin/composer
sudo rm -rf /usr/src/composer
fi
sudo mkdir -m 0777 -p /usr/src/composer
cd /usr/src/composer
# https://getcomposer.org/doc/faqs/how-to-install-composer-programmatically.md
EXPECTED_CHECKSUM="$(php -r 'copy("https://composer.github.io/installer.sig", "php://stdout");')"
sudo php -r "copy('https://getcomposer.org/installer', 'composer-setup.php');"
ACTUAL_CHECKSUM="$(php -r "echo hash_file('sha384', 'composer-setup.php');")"
if [ "$EXPECTED_CHECKSUM" != "$ACTUAL_CHECKSUM" ]; then
fi
sudo mkdir -m 0777 -p /usr/src/composer
cd /usr/src/composer
# https://getcomposer.org/doc/faqs/how-to-install-composer-programmatically.md
EXPECTED_CHECKSUM="$(php -r 'copy("https://composer.github.io/installer.sig", "php://stdout");')"
sudo php -r "copy('https://getcomposer.org/installer', 'composer-setup.php');"
ACTUAL_CHECKSUM="$(php -r "echo hash_file('sha384', 'composer-setup.php');")"
if [ "$EXPECTED_CHECKSUM" != "$ACTUAL_CHECKSUM" ]; then
>&2 echo 'ERROR: Invalid installer checksum'
rm composer-setup.php
exit 1
fi
php composer-setup.php --quiet
sudo cp /usr/src/composer/composer.phar /usr/local/bin/composer
cd - >/dev/null
sudo rm -rf /usr/src/composer/
installed "composer" && composer --version
else
echo "WARNING: You need to have php installed"
fi
# title "Installing composer.phar in home dir..."
# cd ~
# EXPECTED_SIGNATURE="$(wget -q -O - https://composer.github.io/installer.sig)"
# php -r "copy('https://getcomposer.org/installer', 'composer-setup.php');"
# ACTUAL_SIGNATURE="$(php -r "echo hash_file('sha384', 'composer-setup.php');")"
# if [ "$EXPECTED_SIGNATURE" != "$ACTUAL_SIGNATURE" ]
# then
# >&2 echo 'ERROR: Invalid installer signature'
# rm composer-setup.php
# exit 1
# fi
# php composer-setup.php --quiet
# RESULT=$?
# rm composer-setup.php
php composer-setup.php --quiet
sudo cp /usr/src/composer/composer.phar /usr/local/bin/composer
cd - >/dev/null
sudo rm -rf /usr/src/composer/
installed "composer" && composer --version

8
install/flameshot-build Executable file
View File

@@ -0,0 +1,8 @@
#!/bin/bash
##makedesc: [TODO] Build flameshot from src (latest)
echo
echo "==============================================="
echo "Installing flameshot (latest)..."
echo "==============================================="
echo

View File

@@ -10,29 +10,31 @@ echo
installed() {
command -v "$1" >/dev/null 2>&1
}
ENVDIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null 2>&1 && pwd )"
! installed make && sudo apt install -y make
if installed git; then
sudo rm -rf /usr/src/git
sudo git clone https://github.com/git/git.git --depth=1 /usr/src/git
sudo chown -R $USER: /usr/src/git
if [ -d "${HOME}/install/git" ]; then
cd /usr/src/git/ && \
git pull
else
git clone https://github.com/git/git.git --depth=1 "${HOME}/install/git" && \
cd /usr/src/git/
sudo make prefix=/usr/local all
fi
sudo make prefix=/usr/local all && \
sudo make prefix=/usr/local install
else
! installed wget && sudo apt install -y wget
wget https://github.com/git/git/archive/master.zip -O /tmp/git.zip
sudo unzip -q /tmp/git.zip -d /usr/src/git
rm /tmp/git.zip
cd /usr/src/git/git-master
sudo make prefix=/usr/local all
sudo make prefix=/usr/local install
cd /usr/src
sudo rm -rf git
sudo git clone https://github.com/git/git.git --depth=1 /usr/src/git
sudo chown -R $USER: /usr/src/git
[ -d "${HOME}/install/git" ] || mkdir -p "${HOME}/install/git"
wget https://github.com/git/git/archive/master.zip -O /tmp/git.zip && \
unzip -q /tmp/git.zip -d "${HOME}/install/git" && \
rm /tmp/git.zip && \
cd "${HOME}/install/git/git-master" && \
sudo make prefix=/usr/local all && \
sudo make prefix=/usr/local install && \
cd - && \
rm -rf git && \
git clone https://github.com/git/git.git --depth=1 "${HOME}/install/git"
fi
git --version

11
install/libreoffice Executable file
View File

@@ -0,0 +1,11 @@
#!/bin/bash
##makedesc: Install libreoffice
echo
echo "==============================================="
echo "Installing libreoffice..."
echo "==============================================="
echo
sudo apt update && \
sudo apt install -y --autoremove libreoffice

49
install/omz-clean Executable file
View File

@@ -0,0 +1,49 @@
#!/bin/bash
##makedesc: Install omz (latest) + powerline10k + MesloLGS fonts
echo
echo "==============================================="
echo "Installing omz (latest) + powerline10k + MesloLGS fonts..."
echo "==============================================="
echo
installed() {
command -v "$1" >/dev/null 2>&1
}
if ! installed zsh || ! installed git || ! installed curl; then
echo "ERROR: you need git, zsh and curl to be installed!"
exit 1
fi
echo
echo "1. Installing oh-my-zsh..."
sh -c "$(curl -fsSL https://raw.github.com/robbyrussell/oh-my-zsh/master/tools/install.sh)"
echo
echo "2. Installing MesloLGS fonts..."
mkdir -p ~/.local/share/fonts/
wget https://github.com/romkatv/powerlevel10k-media/raw/master/MesloLGS%20NF%20Regular.ttf -O "~/.local/share/fonts/MesloLGS NF Regular.ttf"
wget https://github.com/romkatv/powerlevel10k-media/raw/master/MesloLGS%20NF%20Bold.ttf -O "~/.local/share/fonts/MesloLGS NF Bold.ttf"
wget https://github.com/romkatv/powerlevel10k-media/raw/master/MesloLGS%20NF%20Italic.ttf -O "~/.local/share/fonts/MesloLGS NF Italic.ttf"
wget https://github.com/romkatv/powerlevel10k-media/raw/master/MesloLGS%20NF%20Bold%20Italic.ttf -O "~/.local/share/fonts/MesloLGS NF Bold Italic.ttf"
fc-cache -vf ~/.local/share/fonts/
echo
echo "3. Installing powerlevel10k theme..."
git clone --depth=1 https://github.com/romkatv/powerlevel10k.git ${ZSH_CUSTOM:-$HOME/.oh-my-zsh/custom}/themes/powerlevel10k
sed -i 's#^ZSH_THEME=.*$#ZSH_THEME="powerlevel10k/powerlevel10k"#g' ~/.zshrc
echo
echo "4. Installing plugins..."
git clone https://github.com/zsh-users/zsh-autosuggestions.git ${ZSH_CUSTOM:-$HOME/.oh-my-zsh/custom}/plugins/zsh-autosuggestions
git clone https://github.com/zsh-users/zsh-syntax-highlighting.git ${ZSH_CUSTOM:-$HOME/.oh-my-zsh/custom}/plugins/zsh-syntax-highlighting
sed -i 's/^plugins=/#plugins=/g' ~/.zshrc
echo "plugins=(git laravel docker docker-compose composer zsh-autosuggestions zsh-syntax-highlighting)" >> ~/.zshrc
p10k configure
echo
echo "Finish! You need to:"
echo "- review your plugins in ~/.zshrc"
echo "- log out of your session and login again"
echo

32
install/papirus Executable file
View File

@@ -0,0 +1,32 @@
#!/bin/bash
##makedesc: Install papirus-icon-theme (latest)
echo
echo "==============================================="
echo "Installing papirus-icon-theme (latest)..."
echo "==============================================="
echo
installed() {
command -v "$1" >/dev/null 2>&1
}
if installed git; then
mkdir ${HOME}/install/
git clone https://github.com/PapirusDevelopmentTeam/papirus-icon-theme.git --depth=1 ${HOME}/install/papirus-icon-theme
else
! installed wget && sudo apt install -y wget
mkdir ${HOME}/install/papirus-icon-theme
wget https://github.com/PapirusDevelopmentTeam/papirus-icon-theme/archive/refs/heads/master.zip -O ${HOME}/install/papirus-icon-theme.zip
unzip ${HOME}/install/papirus-icon-theme.zip -d ${HOME}/install/papirus-icon-theme
fi
ln -s ${HOME}/install/papirus-icon-theme/Papirus ${HOME}/.local/share/icons/Papirus
ln -s ${HOME}/install/papirus-icon-theme/Papirus-Dark ${HOME}/.local/share/icons/Papirus-Dark
ln -s ${HOME}/install/papirus-icon-theme/Papirus-Light ${HOME}/.local/share/icons/Papirus-Light
echo
echo "Finish! Don't forget to change current icon theme."
echo "You can find them here:"
echo -e "\t${HOME}/.local/share/icons/"
echo

View File

@@ -7,21 +7,21 @@ echo "Installing postman (latest)..."
echo "==============================================="
echo
wget "https://dl.pstmn.io/download/latest/linux64" -O /tmp/postman.tar.gz
# sudo tar -xvzf /tmp/postman.tar.gz -C /usr/local/bin
sudo tar -xzf /tmp/postman.tar.gz -C /usr/local
rm /tmp/postman.tar.gz
sudo ln -s /usr/local/Postman/Postman /usr/local/bin/postman
echo "#!/usr/bin/env xdg-open
mkdir -p ${HOME}/install/postman
mkdir -p ${HOME}/.local/bin
wget "https://dl.pstmn.io/download/latest/linux64" -O ${HOME}/install/postman.tar.gz && \
tar -xzf ${HOME}/install/postman.tar.gz -C ${HOME}/install/postman && \
ln -s ${HOME}/install/postman/Postman/Postman ${HOME}/.local/bin/postman && \
cat << EOF > ${HOME}/.local/share/applications/Postman.desktop
#!/usr/bin/env xdg-open
[Desktop Entry]
Name=Postman
Exec=/usr/local/bin/postman
Icon=/usr/local/Postman/app/icons/icon_128x128.png
Exec=${HOME}/.local/bin/postman
Icon=${HOME}/install/postman/Postman/app/icons/icon_128x128.png
Categories=Utility,Network
Terminal=false
Type=Application
Encoding=UTF-8
" > $HOME/.local/share/applications/Postman.desktop
EOF
sudo update-desktop-database

25
install/qt5 Executable file
View File

@@ -0,0 +1,25 @@
#!/bin/bash
##makedesc: Install qt5
echo
echo "==============================================="
echo "Installing qt5..."
echo "==============================================="
echo
sudo apt install -y --autoremove \
build-essential \
ca-certificates \
cmake \
g++ \
libqt5core5a \
libqt5dbus5 \
libqt5gui5 \
libqt5network5 \
libqt5svg5 \
libqt5svg5-dev \
libqt5widgets5 \
openssl \
qtbase5-dev \
qttools5-dev \
qttools5-dev-tools

View File

@@ -1,7 +1,7 @@
#!/bin/bash
##makedesc: Install rustdesk v1.1.8 (deb)
##makedesc: Install rustdesk client v1.1.9 (deb)
[ $1 ] && RDVER="$1" || RDVER="1.1.8"
[ $1 ] && RDVER="$1" || RDVER="1.1.9"
echo
echo "==============================================="
echo "Installing rustdesk v${RDVER}..."
@@ -10,7 +10,6 @@ echo
# https://github.com/rustdesk/rustdesk
sudo apt install libxdo3
wget "http://github.com/rustdesk/rustdesk/releases/download/${RDVER}/rustdesk-${RDVER}.deb" -qO /tmp/rustdesk.deb
sudo dpkg -i /tmp/rustdesk.deb
rm /tmp/rustdesk.deb
sudo apt install libxdo3 && \
wget "http://github.com/rustdesk/rustdesk/releases/download/${RDVER}/rustdesk-${RDVER}.deb" -O ${HOME}/install/rustdesk_${RDVER}.deb && \
sudo dpkg -i ${HOME}/install/rustdesk_${RDVER}.deb

View File

@@ -1,56 +1,11 @@
#!/bin/bash
##makedesc: Install zsh + omz (latest)
##makedesc: Install vanilla zsh
echo
echo "==============================================="
echo "Installing zsh + omz (latest)..."
echo "Installing vanilla zsh..."
echo "==============================================="
echo
installed() {
command -v "$1" >/dev/null 2>&1
}
if ! installed git || ! installed curl; then
echo "ERROR: you need git and curl to be installed!"
exit 1
fi
sudo apt install -y --autoremove zsh
# sudo chsh -s $(which zsh)
# Based on:
# https://github.com/Powerlevel9k/powerlevel9k/wiki/Install-Instructions
# https://github.com/ohmyzsh/ohmyzsh
# https://powerline.readthedocs.io/en/latest/installation/linux.html#fonts-installation
# https://gist.github.com/dogrocker/1efb8fd9427779c827058f873b94df95
# https://linuxhint.com/install_zsh_shell_ubuntu_1804/
echo
echo "1. Installing oh-my-zsh..."
sh -c "$(curl -fsSL https://raw.github.com/robbyrussell/oh-my-zsh/master/tools/install.sh)"
echo
echo "2. Installing powerlevel9k theme (legacy)..."
git clone https://github.com/bhilburn/powerlevel9k.git ~/.oh-my-zsh/custom/themes/powerlevel9k
sed -i 's@^ZSH_THEME=.*$@ZSH_THEME="powerlevel9k/powerlevel9k"@g' ~/.zshrc
echo
echo "3. Installing powerline fonts..."
wget https://github.com/powerline/powerline/raw/develop/font/PowerlineSymbols.otf
wget https://github.com/powerline/powerline/raw/develop/font/10-powerline-symbols.conf
mkdir -p ~/.local/share/fonts/
mv PowerlineSymbols.otf ~/.local/share/fonts/
fc-cache -vf ~/.local/share/fonts/
mkdir -p ~/.config/fontconfig/conf.d/
mv 10-powerline-symbols.conf ~/.config/fontconfig/conf.d/
echo
echo "4. Installing autosuggestions and syntax highlighting..."
git clone https://github.com/zsh-users/zsh-autosuggestions.git .oh-my-zsh/custom/plugins/zsh-autosuggestions
git clone https://github.com/zsh-users/zsh-syntax-highlighting.git .oh-my-zsh/custom/plugins/zsh-syntax-highlighting
sed -i 's@plugins=(git)@plugins=(git zsh-autosuggestions zsh-syntax-highlighting)@g' ~/.zshrc
echo
echo "Finish! Log out of your session and login again."
echo
echo "source ~/.profile" >> ~/.zshrc

2
packs/flameshot Normal file
View File

@@ -0,0 +1,2 @@
##flameshot: [TODO] [PACK] qt5 + flameshot from source
flameshot: qt5 flameshot-build

2
packs/lamp Normal file
View File

@@ -0,0 +1,2 @@
##lamp: [PACK] Apache + php + mariadb
lamp: apache php mariadb

View File

@@ -1,2 +0,0 @@
##lamp: Apache + php + mariadb
lamp: apache php mariadb

2
packs/omz Normal file
View File

@@ -0,0 +1,2 @@
##omz: [PACK] zsh + omz + powerline10k + MesloLGS fonts
omz: zsh omz-clean