Install git and mercurial

To make "go get" work in most cases you need either git or mercurial installed to clone the dependencies.
Now the golang class will install these but the requirement to update aptitude (on debian based machines) is not a concern for the golang class and so is handled outside of the class.
This commit is contained in:
Darren Coxall
2014-12-24 13:33:29 +00:00
parent 1448a2deca
commit 413ae77b4f
3 changed files with 27 additions and 3 deletions

View File

@@ -26,4 +26,16 @@ class golang ( $version = "1.4" ) {
unless => "/bin/grep -q GOPATH /home/vagrant/.profile ; /usr/bin/test $? -eq 0"
}
if ! defined(Package["git"]) {
package { "git":
ensure => present,
}
}
if ! defined(Package["mercurial"]) {
package { "mercurial":
ensure => present,
}
}
}