From b75af389985edaed93dacf666fc59b93af3759e7 Mon Sep 17 00:00:00 2001 From: Jake Howard Date: Sat, 31 Mar 2018 18:13:48 +0100 Subject: [PATCH] Add main git config --- modules/config/manifests/init.pp | 9 +++++++++ modules/config/templates/gitconfig.conf.erb | 12 ++++++++++++ 2 files changed, 21 insertions(+) create mode 100644 modules/config/templates/gitconfig.conf.erb diff --git a/modules/config/manifests/init.pp b/modules/config/manifests/init.pp index 2fea529..5d76a2f 100644 --- a/modules/config/manifests/init.pp +++ b/modules/config/manifests/init.pp @@ -50,6 +50,15 @@ class config { source => 'puppet:///modules/config/gitignore_global' } + file { 'Git config': + ensure => file, + path => '/home/jake/.gitconfig', + mode => '0644', + owner => 'jake', + group => 'users', + content => template('config/gitconfig.conf.erb') + } + file { 'Rofi config directory': ensure => directory, mode => '0644', diff --git a/modules/config/templates/gitconfig.conf.erb b/modules/config/templates/gitconfig.conf.erb new file mode 100644 index 0000000..29863ca --- /dev/null +++ b/modules/config/templates/gitconfig.conf.erb @@ -0,0 +1,12 @@ +[core] + excludesfile = ~/.config/.gitignore + +[user] + name = Jake Howard + +[include] +<% if @trusted['hostname'] == 'too-work' -%> + path = ~/.dotfiles/git/work.conf +<% else -%> + path = ~/.dotfiles/git/personal.conf +<% end -%>