Skip to content

Instantly share code, notes, and snippets.

@Avalarion
Created March 8, 2014 14:56
Show Gist options
  • Save Avalarion/9431736 to your computer and use it in GitHub Desktop.
Save Avalarion/9431736 to your computer and use it in GitHub Desktop.
[Attach:] Show Trace in Gitlab CIs Notify Mail
%div{style: "color: white; font-style:monospace; background-color: black; display: block; padding: 5px; width:90%;"}
! Message: #{@build.trace.gsub(/[\n\r]+/,"<br>")}
%div{style: "color: white; font-style:monospace; background-color: black; display: block; padding: 5px; width:90%;"}
! Message: #{@build.trace.gsub(/[\n\r]+/,"<br>")}
@wings27
Copy link

wings27 commented Aug 26, 2016

#{@build.trace.gsub(/[\n\r]+/,"<br>").gsub(/\[0K/, "").gsub(/\[\d+;\d*m/, "")}

remove color tokens such as"[0K" or "[0;m".

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment