[riot-notifications] [RIOT-OS/RIOT] makefiles/color: detect if writing to terminal. (#12127)

Francisco notifications at github.com
Wed Sep 4 11:21:16 CEST 2019


fjmolinas commented on this pull request.



> @@ -8,12 +8,8 @@ COLOR_RESET  :=
 COLOR_ECHO   := /bin/echo
 
 ifeq ($(CC_NOCOLOR),)
-  available_colors:=$(shell tput colors 2> /dev/null)
-  ifeq ($(available_colors),)
-    CC_NOCOLOR = 1
-  else ifeq ($(available_colors),-1)
-    CC_NOCOLOR = 1
-  else ifeq ($(available_colors),0)
+  IS_TERMINAL = $(if $(MAKE_TERMOUT),$(MAKE_TERMERR),)

I can test this solves the issue you point out, but what happens if the terminal itlsed doesn't have multiple color support?

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/RIOT-OS/RIOT/pull/12127#pullrequestreview-283484604
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.riot-os.org/pipermail/notifications/attachments/20190904/c5ed8084/attachment.htm>


More information about the notifications mailing list