mirror of
https://github.com/ivabus/dotfiles
synced 2024-11-10 02:05:16 +03:00
Change visuals
This commit is contained in:
parent
5a972645cb
commit
8ffcd27af0
22
tools/git.sh
22
tools/git.sh
|
@ -2,9 +2,9 @@
|
|||
|
||||
GREEN="\033[32m"
|
||||
RED="\033[31m"
|
||||
DEFAULTC="\033[0m"
|
||||
CLEAR_COLOR="\033[0m"
|
||||
|
||||
echo "${GREEN}Setting up git$DEFAULTC"
|
||||
echo "${GREEN}Setting up git$CLEAR_COLOR"
|
||||
read -p "Enter your name for commits: " GITNAME
|
||||
git config --global user.name "$GITNAME"
|
||||
read -p "Enter your email for commits: " GITEMAIL
|
||||
|
@ -30,17 +30,17 @@ then
|
|||
fi
|
||||
git config --global core.editor $GITEDITOR
|
||||
|
||||
echo "\n${RED}Git configured with:$DEFAULTC"
|
||||
echo "${GREEN}user.name: ${DEFAULTC}$GITNAME"
|
||||
echo "${GREEN}user.email: ${DEFAULTC}$GITEMAIL"
|
||||
echo "${GREEN}core.editor: ${DEFAULTC}$GITEDITOR"
|
||||
echo "${GREEN}pull.rebase: ${DEFAULTC}false (merge)"
|
||||
echo "\n${RED}Git configured with:$CLEAR_COLOR"
|
||||
echo "${GREEN}user.name: ${CLEAR_COLOR}$GITNAME"
|
||||
echo "${GREEN}user.email: ${CLEAR_COLOR}$GITEMAIL"
|
||||
echo "${GREEN}core.editor: ${CLEAR_COLOR}$GITEDITOR"
|
||||
echo "${GREEN}pull.rebase: ${CLEAR_COLOR}false (merge)"
|
||||
|
||||
if [[ $answer = [Yy] ]]
|
||||
then
|
||||
echo "${GREEN}commit.codesign: ${DEFAULTC}true"
|
||||
echo "${GREEN}gpg.program: ${DEFAULTC}gpg2"
|
||||
echo "${GREEN}user.signingkey: ${DEFAULTC}$GPGKEYID"
|
||||
echo "${GREEN}commit.codesign: ${CLEAR_COLOR}true"
|
||||
echo "${GREEN}gpg.program: ${CLEAR_COLOR}gpg2"
|
||||
echo "${GREEN}user.signingkey: ${CLEAR_COLOR}$GPGKEYID"
|
||||
else
|
||||
echo "${GREEN}commit.codesign: ${DEFAULTC}false"
|
||||
echo "${GREEN}commit.codesign: ${CLEAR_COLOR}false"
|
||||
fi
|
|
@ -3,9 +3,9 @@
|
|||
CURRENTDIR="$(pwd)"
|
||||
GREEN="\033[32m"
|
||||
RED="\033[31m"
|
||||
DEFAULTC="\033[0m"
|
||||
CLEAR_COLOR="\033[0m"
|
||||
|
||||
echo "${GREEN}Welcome to ivabus .dotfiles installer$DEFAULTC"
|
||||
echo "${GREEN}Welcome to ivabus .dotfiles installer$CLEAR_COLOR"
|
||||
echo "Dotfiles will be installed to $HOME/.dotfiles"
|
||||
echo "Press enter to continue"
|
||||
read A
|
||||
|
@ -15,12 +15,12 @@ read A
|
|||
if ! command -v zsh > /dev/null
|
||||
then
|
||||
echo "zsh is not installed"
|
||||
echo "${RED}Aborting.$DEFAULTC"
|
||||
echo "${RED}Aborting.$CLEAR_COLOR"
|
||||
exit 255
|
||||
fi
|
||||
|
||||
# install oh-my-zsh and plugins
|
||||
|
||||
echo "${GREEN}Installing oh-my-zsh and plugins$CLEAR_COLOR"
|
||||
ZSH="$HOME/.dotfiles/oh-my-zsh" sh -c "$(curl -fsSL https://raw.githubusercontent.com/ohmyzsh/ohmyzsh/master/tools/install.sh)" "" --unattended > /dev/null
|
||||
curl -fsSL https://raw.githubusercontent.com/ivabus/ivabus-zsh-theme/master/ivabus.zsh-theme -o $HOME/.dotfiles/oh-my-zsh/custom/themes/ivabus.zsh-theme > /dev/null
|
||||
git clone https://github.com/zsh-users/zsh-syntax-highlighting.git $HOME/.dotfiles/oh-my-zsh/custom/plugins/zsh-syntax-highlighting > /dev/null
|
||||
|
@ -28,6 +28,8 @@ git clone https://github.com/zsh-users/zsh-autosuggestions $HOME/.dotfiles/oh-my
|
|||
|
||||
# linking dotfiles to their original locations
|
||||
|
||||
echo "${GREEN}Linking binaries$CLEAR_COLOR"
|
||||
|
||||
sh $HOME/.dotfiles/tools/relink.sh
|
||||
|
||||
cd $CURRENTDIR
|
||||
|
@ -37,7 +39,7 @@ then
|
|||
sh tools/mac.sh
|
||||
fi
|
||||
|
||||
echo "${GREEN}Dotfiles installed and linked.$DEFAULTC"
|
||||
echo "${GREEN}Dotfiles installed and linked.$CLEAR_COLOR"
|
||||
read -p "Would you like to configure git? (y/N): " answer
|
||||
if [[ $answer = [Yy] ]]; then
|
||||
sh tools/git.sh
|
||||
|
|
|
@ -2,13 +2,13 @@
|
|||
|
||||
GREEN="\033[32m"
|
||||
RED="\033[31m"
|
||||
DEFAULTC="\033[0m"
|
||||
CLEAR_COLOR="\033[0m"
|
||||
|
||||
# configuring mac-only things
|
||||
|
||||
# installing homebrew
|
||||
|
||||
echo "${GREEN}Installing Homebrew${DEFAULTC}"
|
||||
echo "${GREEN}Installing Homebrew${CLEAR_COLOR}"
|
||||
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
|
||||
|
||||
if [ "$(arch)" == "arm64" ]
|
||||
|
|
|
@ -4,11 +4,11 @@
|
|||
# do not run manually
|
||||
|
||||
GREEN="\033[32m"
|
||||
DEFAULTC="\033[0m"
|
||||
CLEAR_COLOR="\033[0m"
|
||||
|
||||
mkdir -p $HOME/.config/nvim >/dev/null 2>&1
|
||||
rm $HOME/.zshrc $HOME/.config/nvim/init.vim >/dev/null 2>&1
|
||||
ln -s $HOME/.dotfiles/zshrc $HOME/.zshrc
|
||||
echo "${GREEN}.zshrc linked: $DEFAULTC$HOME/.dotfiles/zshrc $GREEN-> $DEFAULTC$HOME/.zshrc"
|
||||
echo "${GREEN}.zshrc linked: $CLEAR_COLOR$HOME/.dotfiles/zshrc $GREEN-> $CLEAR_COLOR$HOME/.zshrc"
|
||||
ln -s $HOME/.dotfiles/nvim.vim $HOME/.config/nvim/init.vim
|
||||
echo "${GREEN}neovim config linked: $DEFAULTC$HOME/.dotfiles/nvim.vim $GREEN-> $DEFAULTC$HOME/.config/nvim/init.vim"
|
||||
echo "${GREEN}neovim config linked: $CLEAR_COLOR$HOME/.dotfiles/nvim.vim $GREEN-> $CLEAR_COLOR$HOME/.config/nvim/init.vim"
|
||||
|
|
|
@ -5,12 +5,12 @@
|
|||
|
||||
CURRENTDIR="$(pwd)"
|
||||
GREEN="\033[32m"
|
||||
DEFAULTC="\033[0m"
|
||||
CLEAR_COLOR="\033[0m"
|
||||
|
||||
cd $HOME/.dotfiles
|
||||
echo "${GREEN}Upgrading dotfiles$DEFAULTC"
|
||||
echo "1) ${GREEN}Upgrading dotfiles$CLEAR_COLOR"
|
||||
git pull
|
||||
sh tools/relink.sh
|
||||
echo "${GREEN}Upgrading oh-my-zsh$DEFAULTC"
|
||||
echo "2) ${GREEN}Upgrading oh-my-zsh$CLEAR_COLOR"
|
||||
zsh -c "source $ZSH/oh-my-zsh.sh && omz update" > /dev/null
|
||||
cd $CURRENTDIR
|
Loading…
Reference in a new issue