From dc527c216b0e28d486c3231b2011f773676d0109 Mon Sep 17 00:00:00 2001 From: Jake Howard Date: Sat, 12 Aug 2017 18:43:29 +0100 Subject: [PATCH] Add global gitignore --- .gitmodules | 3 +++ {config => modules/config/files}/gitignore_global | 0 modules/config/manifests/init.pp | 12 ++++++++++++ modules/git | 1 + 4 files changed, 16 insertions(+) rename {config => modules/config/files}/gitignore_global (100%) create mode 160000 modules/git diff --git a/.gitmodules b/.gitmodules index 26eafd9..a262bb9 100644 --- a/.gitmodules +++ b/.gitmodules @@ -10,3 +10,6 @@ [submodule "modules/stdlib"] path = modules/stdlib url = https://github.com/puppetlabs/puppetlabs-stdlib +[submodule "modules/git"] + path = modules/git + url = https://github.com/puppetlabs/puppetlabs-git diff --git a/config/gitignore_global b/modules/config/files/gitignore_global similarity index 100% rename from config/gitignore_global rename to modules/config/files/gitignore_global diff --git a/modules/config/manifests/init.pp b/modules/config/manifests/init.pp index 4345fdc..caa19ef 100644 --- a/modules/config/manifests/init.pp +++ b/modules/config/manifests/init.pp @@ -18,4 +18,16 @@ class config { mode => "0644", source => 'puppet:///modules/config/uniemoji.json' } + + file { '/home/jake/.gitignore_global': + ensure => file, + mode => "0644", + source => 'puppet:///modules/config/gitignore_global' + } + + git::config { "global ignore" : + key => 'core.excludesfile', + value => '/home/jake/.gitignore_global', + user => "jake" + } } diff --git a/modules/git b/modules/git new file mode 160000 index 0000000..4e4498e --- /dev/null +++ b/modules/git @@ -0,0 +1 @@ +Subproject commit 4e4498e3db218cefc27e40b7eb4e442177ccab28