source: flair-dev/trunk/cmake-modules/ColoredMessage.cmake@ 83

Last change on this file since 83 was 2, checked in by Sanahuja Guillaume, 8 years ago

initial commit flaircore

File size: 758 bytes
Line 
1
2string(ASCII 27 Esc)
3set(ColourReset "${Esc}[m")
4set(ColourBold "${Esc}[1m")
5set(Red "${Esc}[31m")
6set(Green "${Esc}[32m")
7set(Yellow "${Esc}[33m")
8set(Blue "${Esc}[34m")
9set(Magenta "${Esc}[35m")
10set(Cyan "${Esc}[36m")
11set(White "${Esc}[37m")
12set(BoldRed "${Esc}[1;31m")
13set(BoldGreen "${Esc}[1;32m")
14set(BoldYellow "${Esc}[1;33m")
15set(BoldBlue "${Esc}[1;34m")
16set(BoldMagenta "${Esc}[1;35m")
17set(BoldCyan "${Esc}[1;36m")
18set(BoldWhite "${Esc}[1;37m")
19
20function(info)
21 message("${BoldGreen}${ARGV}${ColourReset}")
22endfunction()
23
24function(warn)
25 message("${BoldYellow}${ARGV}${ColourReset}")
26endfunction()
27
28function(err)
29 message(FATAL_ERROR "${BoldRed}${ARGV}${ColourReset}")
30endfunction()
Note: See TracBrowser for help on using the repository browser.