-
Notifications
You must be signed in to change notification settings - Fork 884
Dotfiles and Boxen #103
Comments
I should note the first time I loaded up Zsh after I installed Boxen, I got this error:
I know what this is doing, just giving an example. |
There are a few approaches to this. The most Puppet-centric way to do it, would be to let Puppet setup symlinks into your dotfiles repo: $home = "/Users/${::boxen_user}"
$dotfiles_dir = "${boxen::config::srcdir}/dotfiles"
repository { $dotfiles_dir:
source => "${::github_user}/dotfiles"
}
file { "${home}/.zshrc":
ensure => link,
target => "${dotfiles_dir}/.zshrc",
require => Repository[$dotfiles_dir]
} Another approach is some folks have a shell script that does all their "install" for dotfiles, and just have Puppet invoke that if appropriate: $home = "/Users/${::boxen_user}"
$dotfiles_dir = "${boxen::config::srcdir}/dotfiles"
repository { $dotfiles_dir:
source => "${::github_user}/dotfiles"
}
exec { "install dotfiles":
cwd => $dotfiles_dir,
command => "./install.sh",
provider => shell,
creates => "${home}/.zshrc",
require => Repository[$dotfiles_dir]
} Both are valid, IMO, so choose the path you prefer. As for the grc load error, my guess is you need to add a [ -f `brew --prefix`/etc/grc.bashrc ] && source `brew --prefix`/etc/grc.bashrc |
I think I owe you at least a few beers now @wfarr. |
My .localrc loads Boxen details, which has Homebrew installs in it. Loading it after .zsh files get loaded means I can't get stuff like the grc suite detected on my path
I've found that I don't need to do much after boxen is installed (I run zsh from Homebrew). As long as my Terminal knows where zsh is, then my dotfiles seem to be fine. |
So, this ties in to #109, because
So, for now, I've just dropped the
Seems to work fine. |
What is the recommended practice for this? I think most of us have them symlinked from git to ~/. Do you suggest symlinking them to 'opt/boxen/config/git' etc, or just letting the two live separate lives?
The text was updated successfully, but these errors were encountered: