C: get name of current shell terminal

Discussion in 'Mac Programming' started by moonman239, Dec 9, 2015.

  1. moonman239 macrumors 68000

    Mar 27, 2009
    I have a C program that outputs a color code that bash understands perfectly well but other terminals may not. The idea, then, would be to have my program color the string according to the rules of the terminal running the program. If it is running in "bash", it will output the string I have so far; if not, and there are no other supported terminals, the program will output a plain string.
  2. cqexbesd macrumors regular

    Jun 4, 2009

Share This Page