Skip to content

Instantly share code, notes, and snippets.

@arvindsv
Created February 14, 2014 04:36
Show Gist options
  • Save arvindsv/8995881 to your computer and use it in GitHub Desktop.
Save arvindsv/8995881 to your computer and use it in GitHub Desktop.
TamperMonkey script for changing the colors on the dashboard of ThoughtWorks' Go
// ==UserScript==
// @name GoChangeColor
// @namespace http://unique.namespace.for.go/
// @version 0.1
// @description Change default colors in ThoughtWorks Go.
// @match http://your.go.server:8153/*
// @copyright 2014, Aravind SV
// ==/UserScript==
(function() {
function changeAllColors() {
var changeColor = function(className, color) {
jQuery(".stage_bar." + className).css("background-color", color);
};
changeColor("Passed", "#8989e9");
changeColor("Building", "yellow");
changeColor("Failing", "#FA2D2D");
changeColor("Failed", "red");
changeColor("Unknown", "red");
changeColor("Cancelled", "yellow");
};
jQuery(document).bind("dashboard-refresh-completed", function (e, notModified) {
changeAllColors();
});
changeAllColors();
})();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment