Остатки: удалён common.sh и пр мелочи

experimental
Anthony Axenov 2022-01-09 17:07:16 +08:00
parent 89086689c8
commit 3f4a7b0504
Signed by: anthony
GPG Key ID: EA9EC32FF7CCD4EC
4 changed files with 9 additions and 66 deletions

View File

@ -7,7 +7,7 @@ echo
# 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
sudo dpkg -i /tmp/google-chrome-stable_current_amd64.deb
rm /tmp/google-chrome-stable_current_amd64.deb

View File

@ -1,10 +1,10 @@
#!/bin/bash
. "../src/01-common.sh" || exit 5
title "Copying dotfiles..."
require_start
# . "../src/01-common.sh" || exit 5
# title "Copying dotfiles..."
# require_start
cp $DOTFILESDIR/.aliases $HOME/.aliases
cp $DOTFILESDIR/.bashrc $HOME/.bashrc
cp $DOTFILESDIR/.zshrc $HOME/.zshrc
cp $DOTFILESDIR/.gitconfig $HOME/.gitconfig
cp -R $DOTFILESDIR/Шаблоны $HOME/Шаблоны
# cp $DOTFILESDIR/.aliases $HOME/.aliases
# cp $DOTFILESDIR/.bashrc $HOME/.bashrc
# cp $DOTFILESDIR/.zshrc $HOME/.zshrc
# cp $DOTFILESDIR/.gitconfig $HOME/.gitconfig
# cp -R $DOTFILESDIR/Шаблоны $HOME/Шаблоны

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

@ -2,18 +2,10 @@
set -e
OLDDIR=`pwd`
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
. "$script"
done
for script in "$INSTALLDIR"/*.sh
do
. "$script"
done
# neofetch