Optionally load files from second/private repo

This commit is contained in:
Jan Jastrow 2022-02-10 21:15:29 +01:00
parent 4a76889d46
commit 346fccde9e
3 changed files with 15 additions and 6 deletions

View File

@ -8,9 +8,16 @@ rm ~/.zshrc
ln -s ~/.dotfiles/zshrc ~/.zshrc ln -s ~/.dotfiles/zshrc ~/.zshrc
touch ~/.dotfiles/zsh/device-specific touch ~/.dotfiles/zsh/device-specific
sudo chsh -s $(which zsh) $USER sudo chsh -s $(which zsh) $USER
echo "Include ~/.dotfiles/ssh/hosts" >> ~/.ssh/config
chmod 600 ~/.dotfiles/ssh/hosts # If private repo is available, add ssh config + hosts
chmod 600 ~/.ssh/config if [[ -d $HOME/.jan ]]; then
echo "Include ~/.jan/ssh_hosts" >> ~/.ssh/hosts
echo "Include ~/.dotfiles/ssh/settings" >> ~/.ssh/config
chmod 600 ~/.ssh/config
chmod 600 ~/.jan/ssh_hosts
fi
# Remove old bash files
rm ~/.bashrc rm ~/.bashrc
rm ~/.bash_logout rm ~/.bash_logout
rm ~/.bash_history rm ~/.bash_history

View File

@ -1,3 +0,0 @@
# Add the following to ~/.ssh/config
# Include ~/.dotfiles/ssh/hosts

5
zshrc
View File

@ -35,6 +35,11 @@ source $HOME/.dotfiles/zsh/scripts
source $HOME/.dotfiles/zsh/ffmpeg source $HOME/.dotfiles/zsh/ffmpeg
source $HOME/.dotfiles/zsh/device-specific source $HOME/.dotfiles/zsh/device-specific
# Load private information from second repo
if [[ -d $HOME/.jan ]]; then
source $HOME/.jan/credentials
fi
# Addons addons # Addons addons
## NNotes ## NNotes