From 3b748919ea14b229931e030f35e475467335ad7b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C5=9Eahin=20Akkaya?= Date: Fri, 25 Mar 2022 21:37:23 +0300 Subject: [PATCH] Remove installation script as it is old --- README.md | 2 +- install-packages.sh | 113 -------------------------------------------- 2 files changed, 1 insertion(+), 114 deletions(-) delete mode 100755 install-packages.sh diff --git a/README.md b/README.md index a2f788c..d9aaf74 100644 --- a/README.md +++ b/README.md @@ -18,5 +18,5 @@ My dotfiles ![Some terminals](https://raw.github.com/Asocia/dotfiles/master/Pictures/Screenshots/ricing/terms.png) ### Todo -- Update the installation script +- Create an installation script diff --git a/install-packages.sh b/install-packages.sh deleted file mode 100755 index bc93fb5..0000000 --- a/install-packages.sh +++ /dev/null @@ -1,113 +0,0 @@ -#!/bin/bash - -# Installation script, use at your own risk. - -# Note: You need to build vim from source. Scroll down for details - -NC='\033[0m' # No Color -RED='\033[0;31m' -GREEN='\033[0;32m' -BLUE='\033[0;34m' -CYAN='\033[0;36m' - - -install_package() { - package=$1 - if dpkg -s $package > /dev/null; then - echo -e "${CYAN}$package ${GREEN}already installed${NC}" - else - sudo apt-get -y install $package - if dpkg -s $package > /dev/null; then - echo "${CYAN}$package ${GREEN}installed${NC}" - else - echo "${CYAN}$package ${RED}failed to install!${NC}" - fi - fi -} - -echo -e "${BLUE}Installing packages...${NC}" - -packages=("zsh" "curl" "git" "tmux") -for package in "${packages[@]}" -do - install_package $package -done -echo -e "${GREEN}Done. ${NC}" - - -echo -e "${BLUE}Installing oh-my-zsh!${NC}" -sh -c "$(curl -fsSL https://raw.githubusercontent.com/ohmyzsh/ohmyzsh/master/tools/install.sh)" "" --unattended -echo -e "${GREEN}Done. ${NC}" - -function dotfiles { - /usr/bin/git --git-dir=$HOME/.cfg/ --work-tree=$HOME $@ -} - - -echo -e "${BLUE}Cloning dotfiles...${NC}" -rm -rf $HOME/.cfg -git clone --bare https://github.com/Asocia/dotfiles.git $HOME/.cfg - -dotfiles checkout -if [ $? = 0 ]; then - : -else - mkdir -p .config-backup - echo "Backing up pre-existing dot files."; - dotfiles checkout 2>&1 | egrep "^\s+." | awk {'print $1'} | xargs -I{} mkdir --parents .config-backup/{} - dotfiles checkout 2>&1 | egrep "^\s+." | awk {'print $1'} | xargs -I{} mv {} .config-backup/{} - dotfiles checkout -fi; -dotfiles config status.showUntrackedFiles no -echo -e "${GREEN}Done. ${NC}" - - -echo -e "${BLUE}Installing custom zsh plugins...${NC}" -git clone --quiet https://github.com/zsh-users/zsh-autosuggestions ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-autosuggestions -git clone --quiet https://github.com/zsh-users/zsh-syntax-highlighting.git ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-syntax-highlighting -git clone --quiet https://github.com/jeffreytse/zsh-vi-mode ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-vi-mode - -git clone --quiet https://github.com/skywind3000/z.lua ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/z.lua -git clone --quiet --depth=1 https://github.com/romkatv/powerlevel10k.git ${ZSH_CUSTOM:-$HOME/.oh-my-zsh/custom}/themes/powerlevel10k -ln -s ~/.aliases ~/.oh-my-zsh/custom/aliases.zsh - -sudo pip3 --quiet install thefuck - -echo -e "${GREEN}Done. ${NC}" - - -echo -e "${BLUE}Changing default shell to zsh...${NC}" -chsh -s $(which zsh) -echo -e "${GREEN}Done. ${NC}" - -# Build vim first -# https://github.com/ycm-core/YouCompleteMe/wiki/Building-Vim-from-source - -# Create required directories -mkdir -p ~/.vim/tmp -mkdir -p ~/.vim/undo -mkdir -p ~/.vim/backup - -echo -e "${BLUE}Installing vim plugins...${NC}" -git clone https://github.com/VundleVim/Vundle.vim.git ~/.vim/bundle/Vundle.vim -curl -fLo ~/.vim/autoload/plug.vim --create-dirs \ - https://raw.githubusercontent.com/junegunn/vim-plug/master/plug.vim - -vim +PluginInstall +qall -vim +PlugInstall +qall -echo -e "${GREEN}Done. ${NC}" -clear; - -echo -e "${BLUE}Installing YCM. This might take a few minutes${NC}" -cd ~/.vim/bundle/YouCompleteMe -python3 install.py --all > /dev/null; -cd -echo -e "${GREEN}Done. ${NC}" - -echo -e "${BLUE}Installing tmux plugins...${NC}" -git clone https://github.com/tmux-plugins/tpm ~/.tmux/plugins/tpm -tmux source-file ~/.tmux.conf -~/.tmux/plugins/tpm/scripts/install_plugins.sh -echo -e "${GREEN}Done. ${NC}" - -echo -e "${GREEN}Installation finished. Log in again to see the effect.${NC}"