Faidon Liambotis has submitted this change and it was merged.
Change subject: rake validate now let puppet output colors
......................................................................
rake validate now let puppet output colors
We have a plugin in Jenkins that let us generate the HTML counterpart of
ANSI escape codes. That will make the console output slighlty nicer.
Change-Id: I3c8f68f0de04a247278acb468e1cf94c434b6d77
---
M rakefile
1 file changed, 5 insertions(+), 14 deletions(-)
Approvals:
Faidon Liambotis: Looks good to me, approved
jenkins-bot: Verified
diff --git a/rakefile b/rakefile
index 40b67a3..476b0c4 100644
--- a/rakefile
+++ b/rakefile
@@ -27,8 +27,6 @@
=end
-$enable_color=false
-
# Only care about color when using a tty
if Rake.application.tty_output?
# Since we are going to use puppet internal stuff, we might as
@@ -40,18 +38,11 @@
$enable_color=true
rescue LoadError
puts "Cant load puppet/util/colors .. no color for you!"
+ # define our own colorization method that simply output the
message
+ def console_color( level, message )
+ return message
+ end
end
-end
-
-# Setup colorization if need be
-if $enable_color
- $puppetcolor = '--color true'
-else
- # define our own colorization method that simply output the message
- def console_color( level, message )
- return message
- end
- $puppetcolor = '--color none'
end
task :default => [:help]
@@ -184,7 +175,7 @@
# Validate manifests passed as an array of filenames
def puppet_parser_validate(*manifests)
manifests = manifests.join(' ')
- sh "puppet parser validate #{$puppetcolor} #{manifests}"
+ sh "puppet parser validate #{manifests}"
end
desc "Run spec tests found in modules"
--
To view, visit https://gerrit.wikimedia.org/r/77381
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: merged
Gerrit-Change-Id: I3c8f68f0de04a247278acb468e1cf94c434b6d77
Gerrit-PatchSet: 3
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Hashar <[email protected]>
Gerrit-Reviewer: Faidon Liambotis <[email protected]>
Gerrit-Reviewer: jenkins-bot
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits