首页 > 技术 > [0;32m eclipse显示颜色

[0;32m eclipse显示颜色

2016年4月7日 发表评论 阅读评论

用 eclipse cdt 运行 gtest 在 console 的输出结果有有 shell 终端的颜色代码输出
Running main() from gmock_main.cc
[==========] Running 4 tests from 1 test case.
[----------] Global test environment set-up.
[----------] 4 tests from PrimeFactors
[ RUN ] PrimeFactors.1factor
[ OK ] PrimeFactors.1factor (0 ms)
[ RUN ] PrimeFactors.2factor
[ OK ] PrimeFactors.2factor (0 ms)
[ RUN ] PrimeFactors.3factor
[ OK ] PrimeFactors.3factor (0 ms)
[ RUN ] PrimeFactors.4factor
[ OK ] PrimeFactors.4factor (0 ms)
[----------] 4 tests from PrimeFactors (0 ms total)

[----------] Global test environment tear-down
[==========] 4 tests from 1 test case ran. (0 ms total)
[ PASSED ] 4 tests.

如何让 console 的输出和 shell 中的输出效果相同。

可以通过在 eclipse market 安装 ANSI escape 来解决。

分类: 技术 标签:
  1. 本文目前尚无任何评论.
  1. 本文目前尚无任何 trackbacks 和 pingbacks.