-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
stripping ANSI codes from GitHub Action control messages (#4167)
Fixes earthly/earthly#4131 GitHub Actions ::error and summary messages do not support ANSI control characters such as colors.
- Loading branch information
1 parent
2131356
commit 31f93b5
Showing
3 changed files
with
22 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -18,3 +18,8 @@ func TestScrubInline(t *testing.T) { | |
s := ScrubCredentialsAll("Here is a URL: https://user:[email protected]/org/repo.git") | ||
Equal(t, "Here is a URL: https://user:[email protected]/org/repo.git", s) | ||
} | ||
|
||
func TestANSICodes(t *testing.T) { | ||
s := ScrubANSICodes("\033[0;32mCommand succeeded.\033[0m") | ||
Equal(t, "Command succeeded.", s) | ||
} |