Compare commits

...

28 Commits

Author SHA1 Message Date
cd0dc9d988
Фиксы $HOME, $USER + dotfiles 2022-01-09 17:14:25 +08:00
3f4a7b0504
Остатки: удалён common.sh и пр мелочи 2022-01-09 17:07:16 +08:00
89086689c8
Корректировка установщика темы для mate 2022-01-09 17:05:31 +08:00
d6344eb7bd
Удалён io.sh 2022-01-09 17:02:54 +08:00
42aba252cd
Корректировка git 2 2022-01-09 17:02:45 +08:00
9e9dfc7174
Корректировка phpstorm-url-handler 2022-01-09 16:59:08 +08:00
d84e756e07
Корректировка wkhtmltopdf 2022-01-09 16:57:18 +08:00
a8f06130ef
Корректировка composer 2022-01-09 16:56:25 +08:00
551f80ef29
Корректировка golang 2022-01-09 16:53:34 +08:00
d025934894
Корректировка telebit 2022-01-09 16:50:40 +08:00
3b0311d8e7
Корректировка postman 2022-01-09 16:49:08 +08:00
28cf415a22
Корректировка chrome 2022-01-09 16:44:33 +08:00
b05640fc00
Корректировка nvm 2022-01-08 14:40:30 +08:00
a5bf6bac4c
Корректировка zint 2022-01-08 14:35:10 +08:00
c4f4452312
Корректировка pgsql 2022-01-08 14:34:20 +08:00
2356787f31
Корректировка mariadb 2022-01-08 14:32:57 +08:00
2039df23f6
Корректировка oci8 (просто чтобы было) 2022-01-08 14:31:10 +08:00
095689194f
Корректировка php 2022-01-08 14:29:07 +08:00
53681a2e66
Корректировка apache2 2022-01-08 14:27:24 +08:00
924e02d9d9
Корректировка Window AppMenu Applet 2022-01-08 14:25:47 +08:00
d7af364574
Корректировка wine 2022-01-08 14:24:16 +08:00
0cbc526452
Корректировка grub-customizer 2022-01-08 14:23:20 +08:00
8f990dfd3e
Корректировка syncthing 2022-01-08 14:20:48 +08:00
12fe7630b1
Корректировка ulauncher 2022-01-08 14:19:41 +08:00
6d46e36f46
Корректировка docker 2022-01-08 14:18:41 +08:00
3db1b4ba9b
Корректировка git 2022-01-08 14:17:50 +08:00
41b6cfbfb3
Корректировка zsh 2022-01-08 14:15:22 +08:00
de926c6987
Проба без доп.скриптов 2022-01-08 13:26:21 +08:00
35 changed files with 399 additions and 419 deletions

View File

@ -1,23 +1,49 @@
# Окружение рабочего стола # Окружение рабочего стола
Установщик софта и визуала. Набор скриптов для развёртывания привычной рабочей среды на Ubuntu.
Используется для развёртывания привычной рабочей среды на Ubuntu.
Для установки всего софта выполнить команду: ## Полная установка
Если установлен `git`
```shell ```shell
git clone git@git.anthonyaxenov.ru:anthony/my-env.git --depth=1
cd my-env
sudo ./start.sh sudo ./start.sh
``` ```
Команда обработает все `*.sh`-скрипты из [`/install`](/install) по порядку. Если не установлен `git`
Если весь софт не нужен, то следует обращаться к этим скриптам по отдельности:
```shell ```shell
./install/050-syncthing.sh wget -qO - http://git.anthonyaxenov.ru/anthony/my-env/archive/master.tar.gz | tar -zxf -
cd my-env
sudo ./start.sh
``` ```
Также можно установить визуальное оформление (**только в среде MATE**): Скрипт `start.sh` обработает все `*.sh`-скрипты из [`/install`](/install) по порядку.
## Частичная установка
Без полного развёртывания репозитория
```shell
wget -qO - http://git.anthonyaxenov.ru/anthony/my-env/raw/branch/master/install/000-apt.sh | bash
```
После полного развёртывания репозитория (см. полную установку):
```shell
cd my-env
sudo ./install/000-apt.sh
```
## Тема оформления (только MATE)
Также можно установить визуальное оформление:
* тема: [Budgie Desktop Dark Theme](https://www.pling.com/p/1276879) * тема: [Budgie Desktop Dark Theme](https://www.pling.com/p/1276879)
* икoнки: [Papirus](https://github.com/PapirusDevelopmentTeam/papirus-icon-theme/) * икoнки: [Papirus](https://github.com/PapirusDevelopmentTeam/papirus-icon-theme/)
* курсоры: [Bridge](https://www.mate-look.org/s/Mate/p/999983/), [Capitaine Cursors](https://www.gnome-look.org/p/1148692/) * курсоры: [Bridge](https://www.mate-look.org/s/Mate/p/999983/), [Capitaine Cursors](https://www.gnome-look.org/p/1148692/)
```shell
sudo ./theme/install.sh
```

View File

@ -1,83 +1,92 @@
[user] [user]
name = AnthonyAxenov name = AnthonyAxenov
email = anthonyaxenov@gmail.com email = anthonyaxenov@gmail.com
[push] signingkey =
default = current [core]
editor = nano
autocrlf = input
[commit]
gpgSign = true
[tag]
gpgSign = true
[pull] [pull]
default = current default = current
rebase = false rebase = false
[core] [push]
editor = nano default = current
autocrlf = input
[alias] [alias]
# общее ----------------------------------------------------------------- # общее -----------------------------------------------------------------
st = status #
aliases = config --get-regexp '^alias' # показать список доступных алиасов aliases = config --get-regexp '^alias' # показать список доступных алиасов
diffc = diff --cached # показать дельту staged-файла head = log -1 HEAD # показать последний коммит в текущей ветке
co = checkout # # название текущей ветки или тега при detached head:
dehead = "!BR=$(git branch --show-current); if [ -n \"$BR\" ]; then echo $BR; else git describe --contains --all HEAD; fi;"
# ветки -------------------------------------------------------------------
bheads = branch -vv # ветки и их последние коммиты
# br = status -sb # показать название текущей ветки
# branch = branch --list -vv # показать текущую ветку в общем списке локальных веток
#mn = merge --no-ff # слить ветку с принудительным коммитом слияния
brd = branch -D # удалить ветку локально
brod = "!git push origin :"${1}";" # удалить ветку на origin
merged = branch --merged # показать список веток, слитых в текущую
review = "!git fetch origin pull/$1/head:pr/$1 && git checkout pr/$1" # github: встать на PR с указанным id
# удалить локальные ветки, слитые в текущую, плюс все мёртвые ссылки на ветки в origin:
trim = "!DEFAULT=master; git branch --merged ${1-$DEFAULT} | grep -v " ${1-$DEFAULT}$" | xargs git branch -d; git remote prune origin;"
# переключение ------------------------------------------------------------
co = checkout # переключиться на ветку/тег/коммит
cob = checkout -b # создание новое ветки cob = checkout -b # создание новое ветки
cp = cherry-pick # применить коммит поверх текущего HEAD master = "!git checkout master && git pull" # переключиться на ветку master и обновить
bheads = branch -vv # показать список веток с последними коммитами dev = "!git checkout dev && git pull" # переключиться на ветку dev и обновить
heads = log --graph --decorate --simplify-by-decoration --oneline # лог только по последним коммитам веток develop = "!git checkout develop && git pull" # переключиться на ветку develop и обновить
# управление ветками ----------------------------------------------------
br = status -sb # показать название текущей ветки
branch = branch --list # показать текущую ветку в общем списке локальных веток
brd = branch -d # удалить слитую ветку локально
brD = branch -D # удалить НЕслитую ветку локально
brod = "!f(){ git branch -d "${1}"; git push origin :"${1}"; };f" # удалить слитую ветку локально и на origin
broD = "!f(){ git branch -D "${1}"; git push origin :"${1}"; };f" # удалить НЕслитую ветку локально и на origin
merged = branch --merged # показать список слитых веток
# удалить все слитые ветки
#bclean = "!f() { DEFAULT=master; git branch --merged ${1-$DEFAULT} | grep -v " ${1-$DEFAULT}$" | xargs git branch -d; }; f"
mn = merge --no-ff # слить ветку с принудительным коммитом слияния
# переключение между ветками ----------------------------------------------
master = "!git checkout master && git pull" # переключиться на ветку master и обновление
dev = "!git checkout dev && git pull" # переключиться на ветку dev и обновление
develop = "!git checkout develop && git pull" # переключиться на ветку develop и обновление
# фиксация изменений ------------------------------------------------------ # фиксация изменений ------------------------------------------------------
c = commit # коммит c = commit # коммит
ca = commit -a # коммит всех файлов ca = commit -a # коммит всех файлов
cm = commit -m # коммит с заданным сообщением cm = commit -m # коммит с заданным сообщением
cam = commit -am # коммит всех файлов с заданным сообщением cam = commit -am # коммит всех файлов с заданным сообщением
amend = commit --amend --no-edit # по-тихому прикрепляет все индексированные файлы к последнему коммиту, используя уже существующее сообщение amend = commit --amend --no-edit # прикрепляет все индексированные файлы к последнему коммиту, используя уже существующее сообщение
# amenda = commit --amend --no-edit -a
amendm = commit --amend -m # прикрепляет все индексированные файлы к последнему коммиту, спрашивает новое сообщение к коммиту amendm = commit --amend -m # прикрепляет все индексированные файлы к последнему коммиту, спрашивает новое сообщение к коммиту
cp = cherry-pick # применить коммит поверх текущего HEAD
diffc = diff --cached # показать дельту staged-файла
uncommit = reset --soft HEAD~1
# управление изменениями, сброс состояний, откат -------------------------- # управление изменениями, сброс состояний, откат --------------------------
st = status -sb # короткий status
rh = reset --hard # откат коммита с удалением всех изменений на указанный коммит rh = reset --hard # откат коммита с удалением всех изменений на указанный коммит
rhh = reset --hard HEAD # откат коммита с удалением всех изменений на последний коммит rhh = reset --hard HEAD # откат коммита с удалением всех изменений на последний коммит
rs = reset --soft # откат коммита с сохранением всех изменений на указанный коммит reseth = reset --mixed HEAD # откат коммита с сохранением всех изменений
rsh = reset --soft HEAD # откат коммита с сохранением всех изменений unstage = reset HEAD # переводит файл staged => unstaged без потери изменений
unstage = reset HEAD # удаляет файл из staged перед коммитом clear = checkout -- # удаляет изменения в файле
clear = checkout -- # удаляет изменения в unstaged-файле
# штучка чтобы не терять наработки, которые ещё в процессе # алиасы для временной фиксации
# на самом деле, надо исопользовать стеш для таких дел # на самом деле, для таких дел надо использовать git stash
# save = !git add -A && git commit -m 'SAVEPOINT' # save = !git add -A && git commit -m 'SAVEPOINT'
# wip = commit -am "WIP" # wip = commit -am "WIP"
# undo = reset HEAD~1 --mixed # undo = reset HEAD~1 --mixed
# работа с remote-репами -------------------------------------------------- # работа с remote-репами --------------------------------------------------
p = push # отправить ветку pushf = push --force # отправить ветку принудительно
po = push origin # отправить ветку в origin pushft = push --tags --force # отправить теги принудительно
pt = push --tags # отправить теги pullf = pull --force # отправить ветки принудительно
pl = pull # получить ветку pullt = pull --tags --force # получить теги принудительно
plo = pull origin # получить ветку из origin #ploh = pull origin HEAD # получить текущую ветку из origin
ploh = pull origin HEAD # получить текущую ветку из origin
remotes = remote -v # показать список удалённых репозиториев remotes = remote -v # показать список удалённых репозиториев
#sy = remote update origin --prune # #sy = remote update origin --prune #
rso = remote show origin # показать состояние локальных веток относительно удалённых на origin bare rso = remote show origin # показать состояние локальных веток относительно удалённых на origin bare
rpo = remote prune origin # удалить все мёртвые ссылки на bare-ветки origin rpo = remote prune origin # удалить все мёртвые ссылки на ветки в origin
repush = 'git push origin :$1 && git push origin $1' # удалить ветку на origin и отправить её заново
# просмотр логов ---------------------------------------------------------- # просмотр логов ----------------------------------------------------------
head = log -1 HEAD # показать последний коммит в текущей ветке heads = log --graph --decorate --simplify-by-decoration --oneline # коммиты, которыми оканчиваются ветки
tree = log --graph --pretty=format:'%C(yellow)%h%C(cyan)%d%Creset %s %C(white)- %an, %ar%Creset'
hist = log --pretty=format:\"%h | %an (%ad) %s%d\" --graph --date=relative hist = log --pretty=format:\"%h | %an (%ad) %s%d\" --graph --date=relative
logfull = log --graph --decorate --all logfull = log --graph --decorate --all
grog = log --graph --decorate --all --pretty=format:'%C(bold red)%h%C(reset) %C(bold blue)%an%C(reset) %C(green)%cr%C(reset) [%aD]%d%n%B' grog = log --graph --decorate --all --pretty=format:'%C(bold red)%h%C(reset) %C(bold blue)%an%C(reset) %C(green)%cr%C(reset) [%aD]%d%n%B'
# подмодули --------------------------------------------------------------- # сабмодули ---------------------------------------------------------------
si = submodule init # инициализация сабмодулей si = submodule init # инициализация сабмодулей
sdi = submodule deinit -f # удаление сабмодуля sdi = submodule deinit -f # удаление сабмодуля
sa = submodule add # добавление сабмодуля sa = submodule add # добавление сабмодуля

View File

@ -2,7 +2,7 @@
# export PATH=$HOME/bin:/usr/local/bin:$PATH # export PATH=$HOME/bin:/usr/local/bin:$PATH
# Path to your oh-my-zsh installation. # Path to your oh-my-zsh installation.
export ZSH="/home/anthony/.oh-my-zsh" export ZSH="$HOME/.oh-my-zsh"
# Set name of the theme to load --- if set to "random", it will # Set name of the theme to load --- if set to "random", it will
# load a random theme each time oh-my-zsh is loaded, in which case, # load a random theme each time oh-my-zsh is loaded, in which case,
@ -103,4 +103,4 @@ source $ZSH/oh-my-zsh.sh
# alias zshconfig="mate ~/.zshrc" # alias zshconfig="mate ~/.zshrc"
# alias ohmyzsh="mate ~/.oh-my-zsh" # alias ohmyzsh="mate ~/.oh-my-zsh"
source ~/.aliases source ~/.bash_aliases

View File

@ -1,10 +1,13 @@
#!/bin/bash #!/bin/bash
. "../src/01-common.sh" || exit 5 echo
title "Installing software from apt..." echo "==============================================="
echo "Installing software from apt..."
echo "==============================================="
echo
aptu sudo apt update && sudo apt upgrade -y --autoremove
aptug sudo apt install -y --autoremove \
apti apt-transport-https \ apt-transport-https \
ca-certificates \ ca-certificates \
curl \ curl \
make \ make \
@ -39,6 +42,9 @@ apti apt-transport-https \
lsp-plugins \ lsp-plugins \
lsb-release \ lsb-release \
net-tools \ net-tools \
nmap \
p7zip-full \
sqlitebrowser \
# minder \ # minder \
# redshift \ # redshift \
# redshift-gtk \ # redshift-gtk \

View File

@ -1,15 +1,22 @@
#!/bin/bash #!/bin/bash
. "../src/01-common.sh" || exit 5 echo
title "Installing snap and its software..." echo "==============================================="
echo "Installing flatpak and its software..."
echo "==============================================="
echo
installed() {
command -v "$1" >/dev/null 2>&1
}
snapi() {
snap install $1 2>/dev/null
[[ $? -ne 0 ]] && snap install $1 --classic
}
if !installed snapd; then if !installed snapd; then
aptu sudo apt update
apti snapd sudo apt install -y --autoremove snapd gnome-software-plugin-snap
apti gnome-software-plugin-snap
# snapi core
# snapi snapd
else
snap refresh core
fi fi
snapi snap-store snapi snap-store
@ -32,6 +39,4 @@ sudo ln -s /snap/bin/certbot /usr/bin/certbot
# snapi mysql-workbench-community # snapi mysql-workbench-community
# snapi dbeaver-ce # snapi dbeaver-ce
# snapi discord # snapi discord
# snapi liquibase
# snapi postman
# snapi obs-studio # snapi obs-studio

View File

@ -1,8 +1,12 @@
#!/bin/bash #!/bin/bash
. "../src/01-common.sh" || exit 5 echo
title "Installing flatpak and its software..." echo "==============================================="
echo "Installing flatpak and its software..."
echo "==============================================="
echo
apti flatpak \ sudo apt install -y --autoremove \
flatpak \
gnome-software-plugin-flatpak gnome-software-plugin-flatpak
flatpak remote-add --if-not-exists flathub https://flathub.org/repo/flathub.flatpakrepo flatpak remote-add --if-not-exists flathub https://flathub.org/repo/flathub.flatpakrepo

View File

@ -1,8 +1,20 @@
#!/bin/bash #!/bin/bash
. "../src/01-common.sh" || exit 5 echo
title "Installing zsh + oh-my-zsh" echo "==============================================="
echo "Installing zsh + oh-my-zsh"
echo "==============================================="
echo
apti zsh 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) # sudo chsh -s $(which zsh)
# Based on: # Based on:
@ -12,16 +24,16 @@ apti zsh
# https://gist.github.com/dogrocker/1efb8fd9427779c827058f873b94df95 # https://gist.github.com/dogrocker/1efb8fd9427779c827058f873b94df95
# https://linuxhint.com/install_zsh_shell_ubuntu_1804/ # https://linuxhint.com/install_zsh_shell_ubuntu_1804/
echo "" echo
echo "1. Installing oh-my-zsh..." echo "1. Installing oh-my-zsh..."
sh -c "$(curl -fsSL https://raw.github.com/robbyrussell/oh-my-zsh/master/tools/install.sh)" sh -c "$(curl -fsSL https://raw.github.com/robbyrussell/oh-my-zsh/master/tools/install.sh)"
echo "" echo
echo "2. Installing powerlevel9k theme (legacy)..." echo "2. Installing powerlevel9k theme (legacy)..."
git clone https://github.com/bhilburn/powerlevel9k.git ~/.oh-my-zsh/custom/themes/powerlevel9k 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 sed -i 's@^ZSH_THEME=.*$@ZSH_THEME="powerlevel9k/powerlevel9k"@g' ~/.zshrc
echo "" echo
echo "3. Installing powerline fonts..." 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/PowerlineSymbols.otf
wget https://github.com/powerline/powerline/raw/develop/font/10-powerline-symbols.conf wget https://github.com/powerline/powerline/raw/develop/font/10-powerline-symbols.conf
@ -31,11 +43,12 @@ fc-cache -vf ~/.local/share/fonts/
mkdir -p ~/.config/fontconfig/conf.d/ mkdir -p ~/.config/fontconfig/conf.d/
mv 10-powerline-symbols.conf ~/.config/fontconfig/conf.d/ mv 10-powerline-symbols.conf ~/.config/fontconfig/conf.d/
echo "" echo
echo "4. Installing autosuggestions and syntax highlighting..." 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-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 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 sed -i 's@plugins=(git)@plugins=(git zsh-autosuggestions zsh-syntax-highlighting)@g' ~/.zshrc
echo "" echo
echo "Finish! Log out of your session and login again." echo "Finish! Log out of your session and login again."
echo

View File

@ -1,12 +1,14 @@
#!/bin/bash #!/bin/bash
. "../src/01-common.sh" || exit 5 echo
title "Installing git..." echo "==============================================="
echo "Installing git..."
echo "==============================================="
echo
if installed 'git'; then if installed git; then
[ ! -d "/usr/src/git" ] && sudo git clone https://github.com/git/git.git --depth=1 /usr/src/git [ ! -d "/usr/src/git" ] && sudo git clone https://github.com/git/git.git --depth=1 /usr/src/git
sudo chown -R anthony: /usr/src/git sudo chown -R $USER: /usr/src/git
cd /usr/src/git/ cd /usr/src/git/
# sudo git pull
sudo make prefix=/usr/local all sudo make prefix=/usr/local all
sudo make prefix=/usr/local install sudo make prefix=/usr/local install
else else
@ -19,6 +21,9 @@ else
cd /usr/src cd /usr/src
sudo rm -rf git sudo rm -rf git
sudo git clone https://github.com/git/git.git --depth=1 /usr/src/git sudo git clone https://github.com/git/git.git --depth=1 /usr/src/git
sudo chown -R anthony: /usr/src/git sudo chown -R $USER: /usr/src/git
fi fi
success "$(git --version)" ENVDIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null 2>&1 && pwd )"
DOTFILESDIR="$ENVDIR"/dotfiles
git --version
cp $DOTFILESDIR/.gitconfig $HOME/.gitconfig

View File

@ -1,21 +1,24 @@
#!/bin/bash #!/bin/bash
. "../src/01-common.sh" || exit 5 echo
title "Installing docker..." echo "==============================================="
echo "Installing docker..."
echo "==============================================="
echo
# https://docs.docker.com/engine/install/ubuntu/ # https://docs.docker.com/engine/install/ubuntu/
# curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add - # curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add -
# sudo add-apt-repository "deb [arch=amd64] https://download.docker.com/linux/ubuntu focal stable" # sudo add-apt-repository "deb [arch=amd64] https://download.docker.com/linux/ubuntu focal stable"
# sudo apt update # sudo apt update
# apti docker-ce docker-compose # sudo apt install -y --autoremove docker-ce docker-compose
curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo gpg --dearmor -o /usr/share/keyrings/docker-archive-keyring.gpg curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo gpg --dearmor -o /usr/share/keyrings/docker-archive-keyring.gpg
echo \ echo \
"deb [arch=$(dpkg --print-architecture) signed-by=/usr/share/keyrings/docker-archive-keyring.gpg] https://download.docker.com/linux/ubuntu \ "deb [arch=$(dpkg --print-architecture) signed-by=/usr/share/keyrings/docker-archive-keyring.gpg] https://download.docker.com/linux/ubuntu \
$(lsb_release -cs) stable" | sudo tee /etc/apt/sources.list.d/docker.list > /dev/null $(lsb_release -cs) stable" | sudo tee /etc/apt/sources.list.d/docker.list > /dev/null
sudo apt update sudo apt update
apti docker-ce docker-ce-cli containerd.io sudo apt install -y --autoremove docker-ce docker-ce-cli containerd.io
sudo usermod -aG docker anthony sudo usermod -aG docker anthony
success "You need to logout and log in again to apply docker group" echo "You need to logout and log in again to apply docker group"

View File

@ -1,6 +1,9 @@
#!/bin/bash #!/bin/bash
. "../src/01-common.sh" || exit 5 echo
title "Installing ulauncher from apt..." echo "==============================================="
echo "Installing ulauncher..."
echo "==============================================="
echo
sudo add-apt-repository ppa:agornostal/ulauncher sudo add-apt-repository ppa:agornostal/ulauncher
apti ulauncher sudo apt install -y --autoremove ulauncher

View File

@ -1,6 +1,9 @@
#!/bin/bash #!/bin/bash
. "../src/01-common.sh" || exit 5 echo
title "Installing syncthing..." echo "==============================================="
echo "Installing syncthing..."
echo "==============================================="
echo
# https://apt.syncthing.net/ # https://apt.syncthing.net/
@ -14,10 +17,10 @@ echo "deb [signed-by=/usr/share/keyrings/syncthing-archive-keyring.gpg] https://
echo "deb [signed-by=/usr/share/keyrings/syncthing-archive-keyring.gpg] https://apt.syncthing.net/ syncthing candidate" | sudo tee /etc/apt/sources.list.d/syncthing.list echo "deb [signed-by=/usr/share/keyrings/syncthing-archive-keyring.gpg] https://apt.syncthing.net/ syncthing candidate" | sudo tee /etc/apt/sources.list.d/syncthing.list
# Update and install syncthing: # Update and install syncthing:
aptu sudo apt update
apti syncthing sudo apt install -y --autoremove syncthing
wget "https://raw.githubusercontent.com/syncthing/syncthing/main/etc/linux-desktop/syncthing-start.desktop" -O /home/anthony/.local/share/applications/syncthing-start.desktop wget "https://raw.githubusercontent.com/syncthing/syncthing/main/etc/linux-desktop/syncthing-start.desktop" -O $HOME/.local/share/applications/syncthing-start.desktop
wget "https://raw.githubusercontent.com/syncthing/syncthing/main/etc/linux-desktop/syncthing-ui.desktop" -O /home/anthony/.local/share/applications/syncthing-ui.desktop wget "https://raw.githubusercontent.com/syncthing/syncthing/main/etc/linux-desktop/syncthing-ui.desktop" -O $HOME/.local/share/applications/syncthing-ui.desktop
ln -s /home/anthony/.local/share/applications/syncthing-start.desktop /home/anthony/.config/autostart/syncthing-start.desktop ln -s $HOME/.local/share/applications/syncthing-start.desktop $HOME/.config/autostart/syncthing-start.desktop
# или демоном: https://habr.com/ru/post/350892/ # или демоном: https://habr.com/ru/post/350892/

View File

@ -1,6 +1,9 @@
#!/bin/bash #!/bin/bash
. "../src/01-common.sh" || exit 5 echo
title "Installing grub-customizer..." echo "==============================================="
echo "Installing grub-customizer..."
echo "==============================================="
echo
sudo add-apt-repository ppa:danielrichter2007/grub-customizer sudo add-apt-repository ppa:danielrichter2007/grub-customizer
apti grub-customizer sudo apt install -y --autoremove grub-customizer

View File

@ -1,9 +1,12 @@
#!/bin/bash #!/bin/bash
. "../src/01-common.sh" || exit 5 echo
title "Installing wine" echo "==============================================="
echo "Installing wine..."
echo "==============================================="
echo
sudo dpkg --add-architecture i386 sudo dpkg --add-architecture i386
wget -qO- https://dl.winehq.org/wine-builds/winehq.key | sudo apt-key add - wget -qO- https://dl.winehq.org/wine-builds/winehq.key | sudo apt-key add -
sudo add-apt-repository 'deb https://dl.winehq.org/wine-builds/ubuntu/ focal main' sudo add-apt-repository 'deb https://dl.winehq.org/wine-builds/ubuntu/ focal main'
apti winehq-stable sudo apt install -y --autoremove winehq-stable
installed "wine" && success "wine installed!" wine --version

View File

@ -1,10 +1,13 @@
#!/bin/bash #!/bin/bash
. "../src/01-common.sh" || exit 5 echo
title "Installing google chrome (latest)..." echo "==============================================="
echo "Installing google chrome (latest)..."
echo "==============================================="
echo
# https://t.me/axenov_blog/251 # https://t.me/axenov_blog/251
# snapi chromium # 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 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 sudo dpkg -i /tmp/google-chrome-stable_current_amd64.deb
rm /tmp/google-chrome-stable_current_amd64.deb rm /tmp/google-chrome-stable_current_amd64.deb

View File

@ -1,24 +1,25 @@
#!/bin/bash #!/bin/bash
. "../src/01-common.sh" || exit 5 echo
title "Installing postman (latest)..." echo "==============================================="
echo "Installing postman (latest)..."
echo "==============================================="
echo
wget "https://dl.pstmn.io/download/latest/linux64" -O /tmp/postman.tar.gz 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 -xvzf /tmp/postman.tar.gz -C /usr/local/bin
sudo tar -xzf /tmp/postman.tar.gz -C /usr/local/bin sudo tar -xzf /tmp/postman.tar.gz -C /usr/local
rm /tmp/postman.tar.gz rm /tmp/postman.tar.gz
sudo ln -s /usr/local/bin/Postman/Postman /usr/local/bin/postman sudo ln -s /usr/local/Postman/Postman /usr/local/bin/postman
echo "#!/usr/bin/env xdg-open echo "#!/usr/bin/env xdg-open
[Desktop Entry] [Desktop Entry]
Name=Postman Name=Postman
Exec=/usr/local/bin/postman Exec=/usr/local/bin/postman
Icon=/usr/local/bin/Postman/app/icons/icon_128x128.png Icon=/usr/local/Postman/app/icons/icon_128x128.png
Categories=Utility,Network Categories=Utility,Network
Terminal=false Terminal=false
Type=Application Type=Application
Encoding=UTF-8 Encoding=UTF-8
" > /home/anthony/.local/share/applications/Postman.desktop " > $HOME/.local/share/applications/Postman.desktop
sudo update-desktop-database sudo update-desktop-database
installed "postman" && success "Postman installed!" || warning "Something wrong, Postman was not installed"

View File

@ -1,6 +1,11 @@
#!/bin/bash #!/bin/bash
. "../src/01-common.sh" || exit 5 echo
title "Installing telebit..." echo "==============================================="
echo "Installing telebit..."
echo "==============================================="
echo
# https://git.coolaj86.com/coolaj86/telebit.js#install
# export NODEJS_VER=v10.2 # v10.2 is tested working, but we can test other versions # export NODEJS_VER=v10.2 # v10.2 is tested working, but we can test other versions
# export TELEBIT_VERSION=master # git tag or branch to install from # export TELEBIT_VERSION=master # git tag or branch to install from

View File

@ -1,16 +1,15 @@
#!/bin/bash #!/bin/bash
. "../src/01-common.sh" || exit 5 echo
title "Installing golang" echo "==============================================="
echo "Installing golang..."
echo "==============================================="
echo
# https://go.dev/dl/
# https://golang.org/doc/install # https://golang.org/doc/install
# https://www.vultr.com/docs/install-the-latest-version-of-golang-on-ubuntu # https://www.vultr.com/docs/install-the-latest-version-of-golang-on-ubuntu
# if [ "$EUID" -ne 0 ] [ $1 ] && VERSION="$1" || VERSION="1.17.6"
# then echo "*** root permissions required ***"
# exit
# fi
[ $1 ] && VERSION="$1" || VERSION="1.17.5"
FILE="go$VERSION.linux-amd64.tar.gz" FILE="go$VERSION.linux-amd64.tar.gz"
sudo rm -rf /usr/local/go sudo rm -rf /usr/local/go
@ -19,9 +18,11 @@ sudo tar -xzf $FILE -C /usr/local
rm -rf /tmp/$FILE rm -rf /tmp/$FILE
sudo chown $USER: -R /usr/local/go sudo chown $USER: -R /usr/local/go
echo "export PATH=$PATH:/usr/local/go/bin" >> /home/anthony/.profile echo "export PATH=$PATH:/usr/local/go/bin" >> $HOME/.profile
echo "export GOPATH=~/.go" >> /home/anthony/.profile echo "export GOPATH=~/.go" >> $HOME/.profile
# source ~/.profile # source ~/.profile
success "$(go version)" echo
info "NOTE: now run \`source ~/.profile\` to apply new env vars" go version
echo "NOTE: now run 'source ~/.profile' to apply new env vars"
echo

View File

@ -1,10 +1,14 @@
#!/bin/bash #!/bin/bash
. "../src/01-common.sh" || exit 5 echo
title "Installing Window AppMenu Applet..." echo "==============================================="
echo "Installing KDE Window AppMenu Applet..."
echo "==============================================="
echo
# https://github.com/psifidotos/applet-window-appmenu/blob/master/INSTALLATION.md # https://github.com/psifidotos/applet-window-appmenu/blob/master/INSTALLATION.md
apti make \ sudo apt install -y --autoremove \
make \
cmake \ cmake \
extra-cmake-modules \ extra-cmake-modules \
qtdeclarative5-dev \ qtdeclarative5-dev \
@ -29,7 +33,9 @@ else
sudo rm -rf /usr/src/appmenu-applet/applet-window-appmenu-master sudo rm -rf /usr/src/appmenu-applet/applet-window-appmenu-master
sudo rm -f /usr/src/appmenu-applet.zip sudo rm -f /usr/src/appmenu-applet.zip
fi fi
sudo chown -R anthony: /usr/src/appmenu-applet sudo chown -R $USER: /usr/src/appmenu-applet
cd /usr/src/appmenu-applet/ cd /usr/src/appmenu-applet/
sh ./install.sh sh ./install.sh
success 'Successful! Now you can add "Window AppMenu Applet" on desktop or panel' echo
echo 'Success! Now you can add "Window AppMenu Applet" on desktop or panel'
echo

View File

@ -1,7 +1,10 @@
#!/bin/bash #!/bin/bash
. "../src/01-common.sh" || exit 5 echo
title "Installing apache2..." echo "==============================================="
echo "Installing apache2..."
echo "==============================================="
echo
apti apache2 sudo apt install -y --autoremove apache2
sudo service apache2 restart sudo service apache2 restart
success "$(apache2 -v)" apache2 -v

View File

@ -1,28 +1,32 @@
#!/bin/bash #!/bin/bash
. "../src/01-common.sh" || exit 5
PHPVER="8.1" PHPVER="8.1"
title "Installing php${PHPVER}..." echo
echo "==============================================="
echo "Installing php${PHPVER}..."
echo "==============================================="
echo
sudo LC_ALL=C.UTF-8 add-apt-repository -y ppa:ondrej/php sudo LC_ALL=C.UTF-8 add-apt-repository -y ppa:ondrej/php
apti php${PHPVER} \ sudo apt install -y --autoremove \
php${PHPVER}-xdebug \ php${PHPVER} \
php${PHPVER}-bcmath \ php${PHPVER}-cli \
php${PHPVER}-bz2 \ php${PHPVER}-common \
php${PHPVER}-curl \ php${PHPVER}-xdebug \
php${PHPVER}-gd \ # php${PHPVER}-bcmath \
php${PHPVER}-json \ # php${PHPVER}-bz2 \
php${PHPVER}-mbstring \ # php${PHPVER}-curl \
php${PHPVER}-mysql \ # php${PHPVER}-gd \
php${PHPVER}-opcache \ # php${PHPVER}-json \
php${PHPVER}-pgsql \ # php${PHPVER}-mbstring \
php${PHPVER}-soap \ # php${PHPVER}-mysql \
php${PHPVER}-xml \ # php${PHPVER}-opcache \
php${PHPVER}-xmlrpc \ # php${PHPVER}-pgsql \
php${PHPVER}-xsl \ # php${PHPVER}-soap \
php${PHPVER}-zip # php${PHPVER}-xml \
# php${PHPVER}-common # php${PHPVER}-xmlrpc \
# php${PHPVER}-cli # php${PHPVER}-xsl \
# php${PHPVER}-dba # php${PHPVER}-sqlite3 \
# php${PHPVER}-ldap # php${PHPVER}-zip
# php${PHPVER}-sqlite3 # php${PHPVER}-dba
# php${PHPVER}-ldap
php -v php -v

View File

@ -1,10 +1,17 @@
#!/bin/bash #!/bin/bash
. "../src/01-common.sh" || exit 5 echo
title "Installing composer..." echo "==============================================="
echo "Installing composer..."
echo "==============================================="
echo
installed() {
command -v "$1" >/dev/null 2>&1
}
if installed "php"; then if installed "php"; then
if installed "composer"; then if installed "composer"; then
warning "You already have composer installed - removing to install actual version" echo "WARNING: You already have composer installed - removing to install actual version"
sudo apt remove -y --autoremove composer sudo apt remove -y --autoremove composer
sudo rm -f /bin/composer sudo rm -f /bin/composer
sudo rm -f /usr/bin/composer sudo rm -f /usr/bin/composer
@ -26,9 +33,9 @@ if installed "php"; then
sudo cp /usr/src/composer/composer.phar /usr/local/bin/composer sudo cp /usr/src/composer/composer.phar /usr/local/bin/composer
cd - >/dev/null cd - >/dev/null
sudo rm -rf /usr/src/composer/ sudo rm -rf /usr/src/composer/
installed "composer" && success "composer installed!" installed "composer" && composer --version
else else
warning "*** You need to have php installed" echo "WARNING: You need to have php installed"
fi fi
# title "Installing composer.phar in home dir..." # title "Installing composer.phar in home dir..."

View File

@ -1,6 +1,9 @@
#!/bin/bash #!/bin/bash
. "../src/01-common.sh" || exit 5 echo
title "Installing oci8..." echo "==============================================="
echo "Installing oci8..."
echo "==============================================="
echo
#check for #check for
# wget https://download.oracle.com/otn_software/linux/instantclient/instantclient-basic-linuxx64.zip # wget https://download.oracle.com/otn_software/linux/instantclient/instantclient-basic-linuxx64.zip
@ -16,14 +19,19 @@ sudo mv ~/Downloads/instant_client/ /opt/oracle/
sudo sh -c "echo /opt/oracle/instant_client > /etc/ld.so.conf.d/oracle-instantclient.conf" sudo sh -c "echo /opt/oracle/instant_client > /etc/ld.so.conf.d/oracle-instantclient.conf"
sudo ldconfig sudo ldconfig
apti php-dev php-pear build-essential libaio1 default-jdk sudo apt install -y --autoremove \
php-dev \
php-pear \
build-essential \
libaio1 \
default-jdk
sudo pecl channel-update pecl.php.net sudo pecl channel-update pecl.php.net
#sudo pecl install oci8 # php8 sudo pecl install oci8 # php8
sudo pecl install oci8-2.2.0 # php7 #sudo pecl install oci8-2.2.0 # php7
#sh -c "echo '; priority=10' > /etc/php/7.4/mods-available/oci8.ini" #sh -c "echo '; priority=10' > /etc/php/7.4/mods-available/oci8.ini"
sudo sh -c "echo 'extension=oci8.so' >> /etc/php/7.4/mods-available/oci8.ini" # sudo sh -c "echo 'extension=oci8.so' >> /etc/php/7.4/mods-available/oci8.ini"
sudo chmod 0644 /etc/php/7.4/mods-available/oci8.ini # sudo chmod 0644 /etc/php/7.4/mods-available/oci8.ini
sudo phpenmod oci8 sudo phpenmod oci8
php -i | grep oci8 php -i | grep oci8
@ -36,4 +44,4 @@ php -i | grep oci8
# https://pecl.php.net/package/oci8 # https://pecl.php.net/package/oci8
sudo pecl install oci8-2.2.0 #sudo pecl install oci8-2.2.0

14
install/800-mariadb.sh Executable file
View File

@ -0,0 +1,14 @@
#!/bin/bash
echo
echo "==============================================="
echo "Installing mariadb..."
echo "==============================================="
echo
installed() {
command -v "$1" >/dev/null 2>&1
}
sudo apt install -y --autoremove mariadb-server mariadb-client
sudo mysql_secure_installation
installed "php" && sudo apt install -y --autoremove php-mysql phpmyadmin

View File

@ -1,8 +0,0 @@
#!/bin/bash
. "../src/01-common.sh" || exit 5
title "Installing mariadb..."
apti mariadb-server mariadb-client
sudo mysql_secure_installation
installed "php" && apti php-mysql phpmyadmin
installed "mysql" && success "mariadb installed!"

View File

@ -1,7 +1,14 @@
#!/bin/bash #!/bin/bash
. "../src/01-common.sh" || exit 5 echo
title "Installing pgsql..." echo "==============================================="
echo "Installing postgresql..."
echo "==============================================="
echo
apti postgresql postgresql-contrib installed() {
command -v "$1" >/dev/null 2>&1
}
sudo apt install -y --autoremove postgresql postgresql-contrib
sudo service postgresql restart sudo service postgresql restart
installed php && apti php-pgsql installed php && sudo apt install -y --autoremove php-pgsql

View File

@ -1,9 +1,12 @@
#!/bin/bash #!/bin/bash
. "../src/01-common.sh" || exit 5 echo
title "Installing wkhtmltopdf..." echo "==============================================="
echo "Installing wkhtmltopdf..."
echo "==============================================="
echo
# не тестировалось # не тестировалось
wget "https://github.com/wkhtmltopdf/packaging/releases/download/0.12.6-1/wkhtmltox_0.12.6-1.focal_amd64.deb" -O /tmp/wkhtmltopdf.deb wget "https://github.com/wkhtmltopdf/packaging/releases/download/0.12.6-1/wkhtmltox_0.12.6-1.focal_amd64.deb" -O /tmp/wkhtmltopdf.deb
sudo dpkg -i /tmp/wkhtmltopdf.deb sudo dpkg -i /tmp/wkhtmltopdf.deb
rm -rf /tmp/wkhtmltopdf.deb rm /tmp/wkhtmltopdf.deb

View File

@ -1,8 +1,16 @@
#!/bin/bash #!/bin/bash
. "../src/01-common.sh" || exit 5 echo
title "Installing zint..." echo "==============================================="
echo "Installing zint..."
echo "==============================================="
echo
apti g++ cmake qtbase5-dev qttools5-dev libpng-dev sudo apt install -y --autoremove \
g++ \
cmake \
qtbase5-dev \
qttools5-dev \
libpng-dev
if installed git; then if installed git; then
# 2.9.* =============================================================================== # 2.9.* ===============================================================================
@ -11,7 +19,6 @@ if installed git; then
sudo cmake . sudo cmake .
sudo make sudo make
sudo make install sudo make install
cd -
else else
echo "You need git to be installed!" echo "You need git to be installed!"
# 2.4.2 =============================================================================== # 2.4.2 ===============================================================================

View File

@ -1,20 +1,28 @@
#!/bin/bash #!/bin/bash
. "../src/01-common.sh" || exit 5 echo
title "Installing nodejs..." echo "==============================================="
echo "Installing nodejs..."
echo "==============================================="
echo
# apti nodejs npm installed() {
command -v "$1" >/dev/null 2>&1
}
# sudo apt install -y --autoremove nodejs npm
if !installed "nvm"; then if !installed "nvm"; then
wget -qO- https://raw.githubusercontent.com/nvm-sh/nvm/master/install.sh | bash wget -qO- https://raw.githubusercontent.com/nvm-sh/nvm/master/install.sh | bash
fi fi
if [ $(nvm current) == 'system' ]; then if [ $(nvm current) == 'system' ]; then
warning "You already have node installed - removing to install actual version" echo "WARNING: You already have node installed - removing to install actual version"
sudo apt remove -y --autoremove nodejs npm sudo apt remove -y --autoremove nodejs npm
else else
nvm install-latest-npm nvm install-latest-npm
fi fi
nvm install node nvm install node
nvm use node nvm use node
installed "node" && success "nodejs installed! $(nvm current)" installed "node" && nvm current
installed "npm" && success "npm installed! $(nvm current)"
nvm ls nvm ls

View File

@ -1,6 +1,13 @@
#!/bin/bash #!/bin/bash
. "../src/01-common.sh" || exit 5 echo
title "Installing phpstorm-url-handler..." echo "==============================================="
echo "Installing phpstorm-url-handler..."
echo "==============================================="
echo
installed() {
command -v "$1" >/dev/null 2>&1
}
# https://github.com/rozwell/phpstorm-url-handler/ # https://github.com/rozwell/phpstorm-url-handler/
# https://askubuntu.com/a/1023143 # https://askubuntu.com/a/1023143
@ -14,9 +21,9 @@ sudo rm -rf /usr/share/applications/phpstorm-url-handler.desktop >/dev/null
if installed "git"; then if installed "git"; then
sudo git clone https://github.com/rozwell/phpstorm-url-handler.git /usr/src/phpstorm-url-handler sudo git clone https://github.com/rozwell/phpstorm-url-handler.git /usr/src/phpstorm-url-handler
else else
sudo wget https://github.com/rozwell/phpstorm-url-handler/archive/master.zip -O /usr/src/phpstorm-url-handler.zip sudo wget https://github.com/rozwell/phpstorm-url-handler/archive/master.zip -O /tmp/phpstorm-url-handler.zip
sudo unzip /usr/src/phpstorm-url-handler.zip -d /usr/src/phpstorm-url-handler sudo unzip /tmp/phpstorm-url-handler.zip -d /usr/src/phpstorm-url-handler
sudo rm -f /usr/src/phpstorm-url-handler.zip sudo rm -f /tmp/phpstorm-url-handler.zip
fi fi
info "Copy .desktop" info "Copy .desktop"

View File

@ -1,9 +1,14 @@
#!/bin/bash #!/bin/bash
. "../src/01-common.sh" || exit 5 echo
title "Copying dotfiles..." echo "==============================================="
require_start echo "Installing dotfiles..."
echo "==============================================="
echo
cp $DOTFILESDIR/.aliases $HOME/.aliases ENVDIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null 2>&1 && pwd )"
DOTFILESDIR="$ENVDIR"/dotfiles
cp $DOTFILESDIR/.bash_aliases $HOME/.bash_aliases
cp $DOTFILESDIR/.bashrc $HOME/.bashrc cp $DOTFILESDIR/.bashrc $HOME/.bashrc
cp $DOTFILESDIR/.zshrc $HOME/.zshrc cp $DOTFILESDIR/.zshrc $HOME/.zshrc
cp $DOTFILESDIR/.gitconfig $HOME/.gitconfig cp $DOTFILESDIR/.gitconfig $HOME/.gitconfig

View File

@ -1,115 +0,0 @@
#!/bin/bash
# https://misc.flogisoft.com/bash/tip_colors_and_formatting
########################################################
# Иконки
########################################################
IINFO="[ i ]"
INOTE="[ * ]"
IWARN="[ # ]"
IERROR="[ ! ]"
IFATAL="[ @ ]"
ISUCCESS="[ ! ]"
IASK="[ ? ]"
########################################################
# Атрибуты текста (форматирование)
########################################################
BOLD="\e[1m" # жирный
_BOLD="\e[21m" # нежирный
DIM="\e[2m" # приглушённый
_DIM="\e[22m" # неприглушённый
NORMAL="\e[20m" # сброс всех атрибутов
RESET="\e[0m" # сброс всех атрибутов и цветов (вообще)
########################################################
# Цвет текста
########################################################
FRESET="\e[39m"
FBLACK="\e[30m"
FWHITE="\e[97m"
FRED="\e[31m"
FGREEN="\e[32m"
FYELLOW="\e[33m"
FBLUE="\e[34m"
FLRED="\e[91m"
FLGREEN="\e[92m"
FLYELLOW="\e[93m"
FLBLUE="\e[94m"
########################################################
# Цвет фона текста
########################################################
BRESET="\e[49m"
BBLACK="\e[40m"
BWHITE="\e[107m"
BRED="\e[41m"
BGREEN="\e[42m"
BYELLOW="\e[43m"
BBLUE="\e[44m"
BLRED="\e[101m"
BLGREEN="\e[102m"
BLYELLOW="\e[103m"
BLBLUE="\e[104m"
########################################################
# Функции для вывода текста
########################################################
print() {
echo -e "$*${RESET}"
}
ask() {
IFS= read -rp "$(print ${BOLD}${BBLUE}${FWHITE}${IASK}${BRESET}\ ${BOLD}$1 ): " $2
}
dbg() {
print "${DIM}$*"
}
info() {
print "${BOLD}${FWHITE}${IINFO}${RESET}${FWHITE} $1 "
}
note() {
print "${BOLD}${DIM}${FWHITE}${INOTE}${RESET} $1 "
}
success() {
print "${BOLD}${BGREEN}${FWHITE}${ISUCCESS}${BRESET}$FGREEN $1 "
}
warn() {
print "${BOLD}${BYELLOW}${FBLACK}${IWARN}${BRESET}${FYELLOW} Warning:${RESET} $1 " >&2
}
error() {
print "${BOLD}${BLRED}${FWHITE}${IERROR} Error: ${BRESET}${FLRED} $1 " >&2
}
fatal() {
print "${BOLD}${BRED}${FWHITE}${IFATAL} FATAL: $1 " >&2
}
########################################################
# Тестирование
########################################################
# print
# print "print test"
# print
# ask "ask test" test
# print $test
# dbg "debug test"
# info "info test"
# note "note test"
# success "success test"
# warn "warn test"
# error "error test"
# fatal "fatal test"

View File

@ -1,49 +0,0 @@
#!/bin/bash
set -e
source "./../src/00-io.sh"
title() {
info ""
info "==============================================="
info " $1"
info "==============================================="
info ""
}
apti() {
sudo apt install -y --autoremove $@
}
aptu() {
sudo apt update
}
aptug() {
sudo apt upgrade -y --autoremove
}
snapi() {
snap install $1 2>/dev/null
[[ $? -ne 0 ]] && snap install $1 --classic
}
installed() {
command -v "$1" >/dev/null 2>&1
}
die() {
error "$1"
exit $2 || 1
}
require_root() {
[ $(id -u) > "0" ] && die "You must run this script with sudo!" 1
}
require_user() {
[ $(id -u) == "0" ] && die "You must run this script WITHOUT sudo!" 2
}
require_start() {
[ -z "$ENVDIR" ] && die "You must run start.sh to execute this script!" 3
}

View File

@ -1,19 +1,6 @@
#!/bin/bash #!/bin/bash
set -e set -e
OLDDIR=`pwd` for script in "$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null 2>&1 && pwd )"/install/*.sh
ENVDIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null 2>&1 && pwd )"
ENVSRCDIR="$ENVDIR"/src
INSTALLDIR="$ENVDIR"/install
DOTFILESDIR="$ENVDIR"/dotfiles
for script in "$ENVSRCDIR"/*.sh
do do
. "$script" . "$script"
done done
for script in "$INSTALLDIR"/*.sh
do
. "$script"
done
# neofetch

View File

@ -1,41 +1,34 @@
#!/bin/bash #!/bin/bash
. "../src/01-common.sh" || exit 5 echo
title "Installing theme..." echo "==============================================="
echo "Installing theme..."
echo "==============================================="
echo
# theme # theme
# sudo cp -R ../theme/Budgie /usr/share/themes/Budgie sudo cp -R ../theme/Budgie /usr/share/themes/Budgie
# cursor # cursor
# sudo cp -R ../theme/Bridge /usr/share/icons/Bridge sudo cp -R ../theme/Bridge /usr/share/icons/Bridge
# sudo cp -R ../theme/Capitaine /usr/share/icons/Capitaine sudo cp -R ../theme/Capitaine /usr/share/icons/Capitaine
# icons # icons
# if installed "git"; then if installed "git"; then
sudo git clone https://github.com/PapirusDevelopmentTeam/papirus-icon-theme.git /usr/src/papirus sudo git clone https://github.com/PapirusDevelopmentTeam/papirus-icon-theme.git /usr/src/papirus
<<<<<<< HEAD:theme/install.sh
else else
sudo wget https://github.com/PapirusDevelopmentTeam/papirus-icon-theme/archive/master.zip -O /usr/src/papirus.zip sudo wget https://github.com/PapirusDevelopmentTeam/papirus-icon-theme/archive/master.zip -O /usr/src/papirus.zip
sudo unzip /usr/src/papirus.zip -d /usr/src/papirus sudo unzip /usr/src/papirus.zip -d /usr/src/papirus
sudo rm -f /usr/src/papirus.zip sudo rm -f /usr/src/papirus.zip
fi fi
sudo chown -R anthony: /usr/src/papirus sudo ln -s /usr/src/papirus/ePapirus /usr/share/icons/ePapirus
=======
# else
# sudo wget https://github.com/PapirusDevelopmentTeam/papirus-icon-theme/archive/master.zip -O /usr/src/papirus.zip
# sudo unzip /usr/src/papirus.zip -d /usr/src/papirus
# sudo rm -f /usr/src/papirus.zip
# fi
>>>>>>> 80482acf7ae67d27edcc5d00c9836e94016f0fed:install/010-theme.sh
# sudo ln -s /usr/src/papirus/ePapirus /usr/share/icons/ePapirus
sudo ln -s /usr/src/papirus/Papirus /usr/share/icons/Papirus sudo ln -s /usr/src/papirus/Papirus /usr/share/icons/Papirus
sudo ln -s /usr/src/papirus/Papirus-Dark /usr/share/icons/Papirus-Dark sudo ln -s /usr/src/papirus/Papirus-Dark /usr/share/icons/Papirus-Dark
sudo ln -s /usr/src/papirus/Papirus-Light /usr/share/icons/Papirus-Light sudo ln -s /usr/src/papirus/Papirus-Light /usr/share/icons/Papirus-Light
# dconf write /org/mate/marco/general/theme "'Budgie'" dconf write /org/mate/marco/general/theme "'Budgie'"
# dconf write /org/mate/desktop/interface/gtk-theme "'Budgie'" dconf write /org/mate/desktop/interface/gtk-theme "'Budgie'"
# dconf write /org/mate/desktop/interface/icon-theme "'Papirus-Dark'" dconf write /org/mate/desktop/interface/icon-theme "'Papirus-Dark'"
# dconf write /org/mate/desktop/peripherals/mouse/cursor-theme "'Capitaine'" dconf write /org/mate/desktop/peripherals/mouse/cursor-theme "'Capitaine'"
# dconf write /org/mate/desktop/peripherals/mouse/cursor-size 20 dconf write /org/mate/desktop/peripherals/mouse/cursor-size 20
# dconf write /org/mate/notification-daemon/theme "'coco'" dconf write /org/mate/notification-daemon/theme "'coco'"
# dconf write /org/mate/notification-daemon/popup-location "'top_right'" dconf write /org/mate/notification-daemon/popup-location "'top_right'"