Up.
This commit is contained in:
parent
2187fcf99f
commit
066ff6c2f7
@ -2,9 +2,12 @@
|
|||||||
|
|
||||||
# Logging function
|
# Logging function
|
||||||
log() {
|
log() {
|
||||||
printf "$(tput setaf 4)$(tput bold)>>>>> %s <<<<<$(tput sgr0)" "$1"
|
printf "$(tput setaf 4)$(tput bold)>>>>> %s <<<<<$(tput sgr0)\n" "$1"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
inf() {
|
||||||
|
printf "$(tput setaf 2)$(tput sgr 0 1)%s$(tput sgr0)\n" "$1"
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
# Packages to install
|
# Packages to install
|
||||||
@ -25,6 +28,7 @@ packages=(
|
|||||||
log ">>>>> Begin Arch/Manjaro Linux packages installation <<<<<"
|
log ">>>>> Begin Arch/Manjaro Linux packages installation <<<<<"
|
||||||
|
|
||||||
## Update system
|
## Update system
|
||||||
|
inf "updating system..."
|
||||||
{{- if ne .chezmoi.username "root" }}
|
{{- if ne .chezmoi.username "root" }}
|
||||||
sudo pacman -Syu --noconfirm
|
sudo pacman -Syu --noconfirm
|
||||||
{{- else }}
|
{{- else }}
|
||||||
@ -33,7 +37,7 @@ packages=(
|
|||||||
|
|
||||||
## Install yay
|
## Install yay
|
||||||
if [ ! $(command -v yay) ]; then
|
if [ ! $(command -v yay) ]; then
|
||||||
log "installing yay"
|
inf "installing yay..."
|
||||||
{{- if ne .chezmoi.username "root" }}
|
{{- if ne .chezmoi.username "root" }}
|
||||||
sudo pacman -S --needed --noconfirm git base-devel
|
sudo pacman -S --needed --noconfirm git base-devel
|
||||||
{{- else}}
|
{{- else}}
|
||||||
@ -48,7 +52,7 @@ packages=(
|
|||||||
## Install packages
|
## Install packages
|
||||||
for package in ${packages[@]}; do
|
for package in ${packages[@]}; do
|
||||||
if [ "$(yay -Qq $package 2> /dev/null)" != $package ]; then
|
if [ "$(yay -Qq $package 2> /dev/null)" != $package ]; then
|
||||||
log "installing ${package}..."
|
inf "installing ${package}..."
|
||||||
yay -S --noconfirm $package
|
yay -S --noconfirm $package
|
||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
@ -62,6 +66,7 @@ packages=(
|
|||||||
DEBIAN_FRONTEND=noninteractive
|
DEBIAN_FRONTEND=noninteractive
|
||||||
|
|
||||||
## Add repositories and update system
|
## Add repositories and update system
|
||||||
|
inf "updating system..."
|
||||||
{{- if ne .chezmoi.username "root" }}
|
{{- if ne .chezmoi.username "root" }}
|
||||||
sudo -E apt-get install --yes --no-install-recommends --ignore-missing lsb-release gpg
|
sudo -E apt-get install --yes --no-install-recommends --ignore-missing lsb-release gpg
|
||||||
curl -fsSL 'https://proget.makedeb.org/debian-feeds/makedeb.pub' | gpg --dearmor | sudo tee /usr/share/keyrings/makedeb-archive-keyring.gpg 1> /dev/null
|
curl -fsSL 'https://proget.makedeb.org/debian-feeds/makedeb.pub' | gpg --dearmor | sudo tee /usr/share/keyrings/makedeb-archive-keyring.gpg 1> /dev/null
|
||||||
@ -99,7 +104,7 @@ packages=(
|
|||||||
)
|
)
|
||||||
|
|
||||||
for package in ${packages[@]}; do
|
for package in ${packages[@]}; do
|
||||||
log "installing ${package}..."
|
inf "installing ${package}..."
|
||||||
|
|
||||||
{{- if ne .chezmoi.username "root" }}
|
{{- if ne .chezmoi.username "root" }}
|
||||||
sudo -E apt-get install --yes --no-install-recommends --ignore-missing $package
|
sudo -E apt-get install --yes --no-install-recommends --ignore-missing $package
|
||||||
|
@ -2,7 +2,11 @@
|
|||||||
|
|
||||||
# Logging function
|
# Logging function
|
||||||
log() {
|
log() {
|
||||||
printf "$(tput setaf 4)$(tput bold)>>>>> %s <<<<<$(tput sgr0)" "$1"
|
printf "$(tput setaf 4)$(tput bold)>>>>> %s <<<<<$(tput sgr0)\n" "$1"
|
||||||
|
}
|
||||||
|
|
||||||
|
inf() {
|
||||||
|
printf "$(tput setaf 2)$(tput sgr 0 1)%s$(tput sgr0)\n" "$1"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -23,10 +27,14 @@ log ">>>>> Begin Zsh installation <<<<<"
|
|||||||
|
|
||||||
{{ if (eq .chezmoi.osRelease.id "manjaro" "arch") -}}
|
{{ if (eq .chezmoi.osRelease.id "manjaro" "arch") -}}
|
||||||
|
|
||||||
|
## Update system
|
||||||
|
inf "updating system..."
|
||||||
|
yay -Syu --noconfirm
|
||||||
|
|
||||||
## install packages
|
## install packages
|
||||||
for package in ${packages[@]}; do
|
for package in ${packages[@]}; do
|
||||||
if [ "$(yay -Qq $package 2> /dev/null)" != $package ]; then
|
if [ "$(yay -Qq $package 2> /dev/null)" != $package ]; then
|
||||||
log "installing ${package}..."
|
inf "installing ${package}..."
|
||||||
yay -S --noconfirm $package
|
yay -S --noconfirm $package
|
||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
@ -34,11 +42,21 @@ log ">>>>> Begin Zsh installation <<<<<"
|
|||||||
{{ else if (eq .chezmoi.osRelease.id "debian" "ubuntu") -}}
|
{{ else if (eq .chezmoi.osRelease.id "debian" "ubuntu") -}}
|
||||||
DEBIAN_FRONTEND=noninteractive
|
DEBIAN_FRONTEND=noninteractive
|
||||||
|
|
||||||
|
## Update system
|
||||||
|
inf "updating system..."
|
||||||
|
{{- if ne .chezmoi.username "root" }}
|
||||||
|
sudo -E apt update
|
||||||
|
sudo -E apt upgrade --yes
|
||||||
|
{{- else }}
|
||||||
|
apt update
|
||||||
|
apt upgrade --yes
|
||||||
|
{{- end}}
|
||||||
|
|
||||||
packages=(${packages[@]//starship/})
|
packages=(${packages[@]//starship/})
|
||||||
|
|
||||||
## install packages
|
## install packages
|
||||||
for package in ${packages[@]}; do
|
for package in ${packages[@]}; do
|
||||||
log "installing ${package}..."
|
inf "installing ${package}..."
|
||||||
|
|
||||||
{{- if ne .chezmoi.username "root" }}
|
{{- if ne .chezmoi.username "root" }}
|
||||||
sudo -E apt-get install --yes --no-install-recommends --ignore-missing $package
|
sudo -E apt-get install --yes --no-install-recommends --ignore-missing $package
|
||||||
@ -47,7 +65,7 @@ log ">>>>> Begin Zsh installation <<<<<"
|
|||||||
{{- end }}
|
{{- end }}
|
||||||
done
|
done
|
||||||
|
|
||||||
log "installing starship..."
|
inf "installing starship..."
|
||||||
mist install starship-bin
|
mist install starship-bin
|
||||||
|
|
||||||
{{- end }}
|
{{- end }}
|
||||||
|
@ -2,7 +2,11 @@
|
|||||||
|
|
||||||
# Logging function
|
# Logging function
|
||||||
log() {
|
log() {
|
||||||
printf "$(tput setaf 4)$(tput bold)>>>>> %s <<<<<$(tput sgr0)" "$1"
|
printf "$(tput setaf 4)$(tput bold)>>>>> %s <<<<<$(tput sgr0)\n" "$1"
|
||||||
|
}
|
||||||
|
|
||||||
|
inf() {
|
||||||
|
printf "$(tput setaf 2)$(tput sgr 0 1)%s$(tput sgr0)\n" "$1"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -25,12 +29,13 @@ log ">>>>> Begin LVim installation <<<<<"
|
|||||||
{{ if (eq .chezmoi.osRelease.id "manjaro" "arch") -}}
|
{{ if (eq .chezmoi.osRelease.id "manjaro" "arch") -}}
|
||||||
|
|
||||||
## Update system
|
## Update system
|
||||||
|
inf "updating system..."
|
||||||
yay -Syu --noconfirm
|
yay -Syu --noconfirm
|
||||||
|
|
||||||
## Install packages
|
## Install packages
|
||||||
for package in ${packages[@]}; do
|
for package in ${packages[@]}; do
|
||||||
if [ "$(yay -Qq $package 2> /dev/null)" != $package ]; then
|
if [ "$(yay -Qq $package 2> /dev/null)" != $package ]; then
|
||||||
log "installing ${package}..."
|
inf "installing ${package}..."
|
||||||
yay -S --noconfirm $package
|
yay -S --noconfirm $package
|
||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
@ -40,6 +45,7 @@ log ">>>>> Begin LVim installation <<<<<"
|
|||||||
DEBIAN_FRONTEND=noninteractive
|
DEBIAN_FRONTEND=noninteractive
|
||||||
|
|
||||||
## Update system
|
## Update system
|
||||||
|
inf "updating system..."
|
||||||
{{- if ne .chezmoi.username "root" }}
|
{{- if ne .chezmoi.username "root" }}
|
||||||
sudo -E apt update
|
sudo -E apt update
|
||||||
sudo -E apt upgrade --yes
|
sudo -E apt upgrade --yes
|
||||||
@ -54,7 +60,7 @@ log ">>>>> Begin LVim installation <<<<<"
|
|||||||
packages=(${packages[@]//neovim/})
|
packages=(${packages[@]//neovim/})
|
||||||
|
|
||||||
for package in ${packages[@]}; do
|
for package in ${packages[@]}; do
|
||||||
log "installing ${package}..."
|
inf "installing ${package}..."
|
||||||
|
|
||||||
{{- if ne .chezmoi.username "root" }}
|
{{- if ne .chezmoi.username "root" }}
|
||||||
sudo -E apt-get install --yes --no-install-recommends --ignore-missing $package
|
sudo -E apt-get install --yes --no-install-recommends --ignore-missing $package
|
||||||
@ -63,12 +69,12 @@ log ">>>>> Begin LVim installation <<<<<"
|
|||||||
{{- end }}
|
{{- end }}
|
||||||
done
|
done
|
||||||
|
|
||||||
log "installing neovim..."
|
inf "installing neovim..."
|
||||||
mist install neovim
|
mist install neovim
|
||||||
|
|
||||||
{{- end }}
|
{{- end }}
|
||||||
|
|
||||||
log "installing lvim..."
|
inf "installing lvim..."
|
||||||
LV_BRANCH='release-1.3/neovim-0.9' bash <(curl -s 'https://raw.githubusercontent.com/LunarVim/LunarVim/release-1.3/neovim-0.9/utils/installer/install.sh')
|
LV_BRANCH='release-1.3/neovim-0.9' bash <(curl -s 'https://raw.githubusercontent.com/LunarVim/LunarVim/release-1.3/neovim-0.9/utils/installer/install.sh')
|
||||||
|
|
||||||
log ">>>>> Finish LVim installation <<<<<"
|
log ">>>>> Finish LVim installation <<<<<"
|
||||||
|
Loading…
Reference in New Issue
Block a user