Move from antigen to antidot
This commit is contained in:
37
install.sh
Executable file → Normal file
37
install.sh
Executable file → Normal file
@@ -2,7 +2,7 @@
|
||||
|
||||
## Define Arrays
|
||||
packages=( "zsh" "htop" "figlet" "tmux" "curl" "net-tools" "dnsutils" "tree" )
|
||||
configfiles=( ".zshrc" ".antigen.zsh" ".p10k.zsh" ".tmux.conf" ".config/htop/htoprc" "/usr/share/nano/yaml.nanorc" )
|
||||
configfiles=( ".zshrc" ".zsh_plugins.txt" ".p10k.zsh" ".tmux.conf" ".config/htop/htoprc" "/usr/share/nano/yaml.nanorc" )
|
||||
configfileslinux=( "/etc/nanorc" )
|
||||
motdfiles=( "/etc/update-motd.d/00-header" "/etc/update-motd.d/10-uname" "/etc/update-motd.d/10-sysinfo" "/etc/update-motd.d/90-footer" )
|
||||
|
||||
@@ -15,9 +15,7 @@ else
|
||||
mkdir ~/.config/htop
|
||||
fi
|
||||
|
||||
|
||||
## Install packages
|
||||
|
||||
if [ "$(uname)" = "Darwin" ]; then
|
||||
echo MacOS found - no installation of packages needed.
|
||||
else
|
||||
@@ -36,7 +34,6 @@ echo $i is installed - skipping.
|
||||
fi
|
||||
|
||||
## Remove Config Files
|
||||
|
||||
for j in "${configfiles[@]}"
|
||||
do
|
||||
rm $j
|
||||
@@ -49,7 +46,6 @@ if [ "$(uname)" != "Darwin" ]; then
|
||||
done
|
||||
fi
|
||||
|
||||
|
||||
## Remove Motd Files
|
||||
if [ "$(uname)" = "Darwin" ]; then
|
||||
echo MacOS found - no motd files to remove.
|
||||
@@ -62,8 +58,21 @@ do
|
||||
done
|
||||
fi
|
||||
|
||||
## Install Antigen
|
||||
curl -L git.io/antigen > .antigen.zsh
|
||||
## Remove Antigen if installed
|
||||
if [ -d ~/.antigen ]; then
|
||||
echo Antigen is installed. Removing...
|
||||
rm -R ~/.antigen
|
||||
rm ~/.antigen.zsh
|
||||
fi
|
||||
|
||||
|
||||
## Install Antidote - replacement of Antigen
|
||||
if test -f ~/.antidote; then
|
||||
echo "Antidote allready installed."
|
||||
else
|
||||
echo "Installing antidote..."
|
||||
git clone --depth=1 https://github.com/mattmc3/antidote.git ${ZDOTDIR:-~}/.antidote
|
||||
fi
|
||||
|
||||
## Create Symlinks
|
||||
ln -s ~/.zshconfig/zshrc .zshrc
|
||||
@@ -71,21 +80,11 @@ ln -s ~/.zshconfig/yaml.nanorc /usr/share/nano/yaml.nanorc
|
||||
ln -s ~/.zshconfig/tmux .tmux.conf
|
||||
ln -s ~/.zshconfig/htoprc .config/htop/htoprc
|
||||
ln -s ~/.zshconfig/p10k.zsh .p10k.zsh
|
||||
if [ "$(uname)" != "Darwin" ]; then
|
||||
ln -s ~/.zshconfig/nanorc /etc/nanorc
|
||||
else
|
||||
echo MacOS found - No linking of Nanorc needed.
|
||||
fi
|
||||
|
||||
|
||||
ln -s ~/.zshconfig/.zsh_plugins.txt .zsh_plugins.txt
|
||||
ln -s ~/.zshconfig/nanorc /etc/nanorc
|
||||
|
||||
## Make ZSH as default Shell
|
||||
if [ "$(uname)" = "Darwin" ]; then
|
||||
echo MacOS found - ZSH is already default shell.
|
||||
else
|
||||
chsh -s $(which zsh)
|
||||
fi
|
||||
|
||||
|
||||
## Copy Files, fix permissions
|
||||
if [ "$(uname)" = "Darwin" ]; then
|
||||
|
||||
Reference in New Issue
Block a user