Escape chars in output of `gitlab-runner list`
Version: gitlab-runner version 1.1.4 (9e2fd1a)
I was very confused why my sed regexps did not work as intended. Unless I saw output from Ansible verbose mode, it's quite interesting:
[root@XXXX config]# gitlab-runner list --config /home_local/gitlab-runner/.gitlab-runner/config.toml
Listing configured runners ConfigFile=/home_local/gitlab-runner/.gitlab-runner/config.toml
XXX Executor=shell Token=XXXX URL=XXX
[root@XXXX config]# gitlab-runner list --config /home_local/gitlab-runner/.gitlab-runner/config.toml 2>&1 | less
Listing configured runners ESC[0;m ConfigFileESC[0;m=/home_local/gitlab-runner/.gitlab-runner/config.toml
XXX ESC[0;m ExecutorESC[0;m=shell TokenESC[0;m=XXX URLESC[0;m=XXX
There are escape characters inserted, ESC[0;m
is (afaik, maybe I'm wrong here) clear construction which disables styling modifications after this. I can overcome this but why there are escape characters there ? It complicates the manipulations on text and colors and only used in Debug mode, within header.