Use rcm instead of ./install.sh
The rcm suite is designed to replace the `./install.sh` script found in this and many other dotfiles repos across GitHub. By using rcm users can combine multiple dotfiles repos, tag dotfiles, have host-specific dotfiles, and other powerful features. This commit removes `install.sh`, updates the README, adds a post-up hook that vundles the vim bundles, and adds a `rcrc` configuration that ignores `README.md` and `LICENSE` and sets the dotfiles directory to just `dotfiles`.
This commit is contained in:
parent
4f65f7927c
commit
3bc2a98a1b
4 changed files with 21 additions and 25 deletions
17
README.md
17
README.md
|
@ -8,6 +8,11 @@ Set zsh as your login shell.
|
|||
|
||||
chsh -s /bin/zsh
|
||||
|
||||
Install [rcm](https://github.com/mike-burns/rcm).
|
||||
|
||||
brew tap mike-burns/rcm
|
||||
brew install rcm
|
||||
|
||||
Install
|
||||
-------
|
||||
|
||||
|
@ -20,12 +25,16 @@ updated](http://robots.thoughtbot.com/keeping-a-github-fork-updated)).
|
|||
|
||||
Install:
|
||||
|
||||
cd dotfiles
|
||||
./install.sh
|
||||
rcup -d dotfiles -x README.md -x LICENSE
|
||||
|
||||
This will create symlinks for config files in your home directory.
|
||||
This will create symlinks for config files in your home directory. The
|
||||
`-x` options, which exclude the `README.md` and `LICENSE` files, are
|
||||
needed during installation but can be skipped once the `.rcrc`
|
||||
configuration file is symlinked in.
|
||||
|
||||
You can safely run `./install.sh` multiple times to update.
|
||||
You can safely run `rcup` multiple times to update:
|
||||
|
||||
rcup
|
||||
|
||||
Make your own customizations
|
||||
----------------------------
|
||||
|
|
6
hooks/post-up
Executable file
6
hooks/post-up
Executable file
|
@ -0,0 +1,6 @@
|
|||
#!/bin/sh
|
||||
|
||||
if [ ! -e $HOME/.vim/bundle/vundle ]; then
|
||||
git clone https://github.com/gmarik/vundle.git $HOME/.vim/bundle/vundle
|
||||
vim -u $HOME/.vimrc.bundles +BundleInstall +qa
|
||||
fi
|
21
install.sh
21
install.sh
|
@ -1,21 +0,0 @@
|
|||
#!/bin/sh
|
||||
|
||||
for name in *; do
|
||||
target="$HOME/.$name"
|
||||
if [ -e "$target" ]; then
|
||||
if [ ! -L "$target" ]; then
|
||||
echo "WARNING: $target exists but is not a symlink."
|
||||
fi
|
||||
else
|
||||
if [ "$name" != 'install.sh' ] && [ "$name" != 'README.md' ] && ["$name" != 'LICENSE' ]; then
|
||||
echo "Creating $target"
|
||||
ln -s "$PWD/$name" "$target"
|
||||
fi
|
||||
fi
|
||||
done
|
||||
|
||||
if [ ! -e ~/.vim/bundle/vundle ]; then
|
||||
git clone https://github.com/gmarik/vundle.git ~/.vim/bundle/vundle
|
||||
fi
|
||||
|
||||
vim -u ~/.vimrc.bundles +BundleInstall +qa
|
2
rcrc
Normal file
2
rcrc
Normal file
|
@ -0,0 +1,2 @@
|
|||
EXCLUDES="README.md LICENSE"
|
||||
DOTFILES_DIRS="$HOME/dotfiles"
|
Loading…
Add table
Reference in a new issue