changeset 395:fa2747b27bb4

Fix git-prompt in Ubuntu They package it different and have another path
author IBBoard <dev@ibboard.co.uk>
date Mon, 18 Apr 2022 10:37:00 +0100
parents 687aa581eef0
children e93588ec1ce3
files modules/vcs/manifests/init.pp
diffstat 1 files changed, 7 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/modules/vcs/manifests/init.pp	Sat Apr 09 18:51:03 2022 +0100
+++ b/modules/vcs/manifests/init.pp	Mon Apr 18 10:37:00 2022 +0100
@@ -17,9 +17,15 @@
     python::pip { 'keyrings.alt':
         ensure => 'present',
     }
+    if $operatingsystem == 'Ubuntu' {
+        $gitprompt = '/etc/bash_completion.d/git-prompt'
+    }
+    else {
+        $gitprompt = '/usr/share/git-core/contrib/completion/git-prompt.sh'
+    }
     file { '/etc/bash_completion.d/git-prompt.sh':
         ensure => 'link',
-        target => '/usr/share/git-core/contrib/completion/git-prompt.sh',
+        target => $gitprompt,
     }
 }