mirror of
https://github.com/lawrencesystems/dotfiles.git
synced 2024-11-09 23:24:11 -08:00
Update doco & add automation
Add some automation into the apt install, so that you don't need to worry about that. Make sure the apt update runs successfully before doing the install Add documentation.
This commit is contained in:
parent
b448030a33
commit
73675cd237
15
install.sh
15
install.sh
|
@ -1,15 +1,20 @@
|
|||
#!/bin/bash
|
||||
|
||||
# Find all dot files then if the original file exists, create a backup
|
||||
# Once backed up to {file}.dtbak symlink the new dotfile in place
|
||||
for file in $(find . -maxdepth 1 -name ".*" -type f -printf "%f\n" ); do
|
||||
if [ -e ~/$file ]; then
|
||||
mv -f ~/$file{,.dtbak}
|
||||
fi
|
||||
ln -s $PWD/$file ~/$file
|
||||
done
|
||||
if hash vim-addon 2>/dev/null; then
|
||||
echo "vim-addon (vim-scripts) installed"
|
||||
else
|
||||
echo "vim-addon (vim-scripts) not installed, running 'sudo apt update; sudo apt install bc'"
|
||||
sudo apt update; sudo apt install vim-scripts
|
||||
|
||||
# Check if vim-addon installed, if not, install it automatically
|
||||
if hash vim-addon 2>/dev/null; then
|
||||
echo "vim-addon (vim-scripts) installed"
|
||||
else
|
||||
echo "vim-addon (vim-scripts) not installed, installing"
|
||||
sudo apt update && sudo apt -y install vim-scripts
|
||||
fi
|
||||
|
||||
echo "Installed"
|
||||
|
|
Loading…
Reference in a new issue