diff --git a/modules/people/manifests/hanjianwei.pp b/modules/people/manifests/hanjianwei.pp index 187275f..32bf82d 100644 --- a/modules/people/manifests/hanjianwei.pp +++ b/modules/people/manifests/hanjianwei.pp @@ -1,4 +1,8 @@ -class people::hanjianwei { +class people::hanjianwei ( + $home = $people::hanjianwei::config::home, + $dotfiles = $people::hanjianwei::config::dotfiles, + $srcdir = $people::hanjianwei::config::srcdir +) inherits people::hanjianwei::config { include people::hanjianwei::osx include people::hanjianwei::repositories include people::hanjianwei::applications diff --git a/modules/people/manifests/hanjianwei/applications.pp b/modules/people/manifests/hanjianwei/applications.pp index d7108e6..0a4c1be 100644 --- a/modules/people/manifests/hanjianwei/applications.pp +++ b/modules/people/manifests/hanjianwei/applications.pp @@ -1,5 +1,7 @@ -class people::hanjianwei::applications inherits people::hanjianwei::config { - notify { "${homebrew::config::cachedir}": } +class people::hanjianwei::applications( + $home = $people::hanjianwei::config::home, + $dotfiles = $people::hanjianwei::config::dotfiles +) { # Declare all Homebrew packages package { @@ -53,7 +55,7 @@ class people::hanjianwei::applications inherits people::hanjianwei::config { 'welly', 'xmind' ]: - provider => 'brewcask' + provider => 'brewcask' } # Taps diff --git a/modules/people/manifests/hanjianwei/mirrors.pp b/modules/people/manifests/hanjianwei/mirrors.pp index 07e64d2..b148ab1 100644 --- a/modules/people/manifests/hanjianwei/mirrors.pp +++ b/modules/people/manifests/hanjianwei/mirrors.pp @@ -1,7 +1,10 @@ -class people::hanjianwei::mirrors inherits people::hanjianwei::config { +class people::hanjianwei::mirrors( + $home = $people::hanjianwei::config::home, + $dotfiles = $people::hanjianwei::config::dotfiles +) { include boxen::gemrc - File <| title == "/Users/${::boxen_user}/.gemrc" |> { + File <| title == "${home}/.gemrc" |> { source => "${dotfiles}/Gem/gemrc", require => Repository["${dotfiles}"] } diff --git a/modules/people/manifests/hanjianwei/osx.pp b/modules/people/manifests/hanjianwei/osx.pp index ce9dfa0..06a4535 100644 --- a/modules/people/manifests/hanjianwei/osx.pp +++ b/modules/people/manifests/hanjianwei/osx.pp @@ -1,4 +1,7 @@ -class people::hanjianwei::osx inherits people::hanjianwei::config { +class people::hanjianwei::osx( + $home = $people::hanjianwei::config::home, + $dotfiles = $people::hanjianwei::config::dotfiles +) { # Zsh osx_chsh { $boxen_user: shell => '/bin/zsh' diff --git a/modules/people/manifests/hanjianwei/repositories.pp b/modules/people/manifests/hanjianwei/repositories.pp index 2e340d5..e55ecd3 100644 --- a/modules/people/manifests/hanjianwei/repositories.pp +++ b/modules/people/manifests/hanjianwei/repositories.pp @@ -1,4 +1,9 @@ -class people::hanjianwei::repositories inherits people::hanjianwei::config { +class people::hanjianwei::repositories( + $home = $people::hanjianwei::config::home, + $dotfiles = $people::hanjianwei::config::dotfiles, + $srcdir = $people::hanjianwei::config::srcdir +) { + # Git file { "${home}/.gitconfig": target => "${dotfiles}/Git/gitconfig", @@ -9,4 +14,8 @@ class people::hanjianwei::repositories inherits people::hanjianwei::config { repository { "${dotfiles}": source => 'hanjianwei/dotfiles' } + + repository { "${srcdir}/diyao/web": + source => 'hanjianwei/diyao-web' + } }