marcells / node-build-monitor

A Build Monitor written in Node.js, which supports several build services and can be easily extended.
https://marcells.github.io/node-build-monitor
MIT License
349 stars 168 forks source link

Move color-definition of build-state to global scope #232

Open ehmkah opened 3 years ago

ehmkah commented 3 years ago

Many different build-systems are supported and the state of the build is mapped to a color. This mapping is implemented in getBuildStatus. It would be nice to have a global defined mapping of states to color. It would make it

e.g for such a mapping could be (taken from https://github.com/marcells/node-build-monitor/blob/master/app/services/Tfs.js)

 const colorScheme = Object.freeze({
    succeeded:          'Green',
    partiallySucceeded: '#F8A800',
    failed:             'Red',
    canceled:           'Gray',
    inProgress:         '#0078D7',
    completed:          'Green',
    cancelling:         '#0078D7',
    postponed:          'Gray',
    notStarted:         'Gray',
    all:                'Gray'
  });
marcells commented 3 years ago

Good idea. You can implement it, if you want to.