koch remove dead code (#20912)

* koch remove dead code for Travis CI

* Restart CI

* Restart CI
This commit is contained in:
Juan Carlos 2022-11-25 09:51:11 -03:00 • committed by GitHub
commit 2709898a5e
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -61,25 +61,18 @@ proc exec*(cmd: string, errorcode: int = QuitFailure, additionalPath = "") =
putEnv("PATH", prevPath) putEnv("PATH", prevPath)
template inFold*(desc, body) = template inFold*(desc, body) =
if existsEnv("TRAVIS"): if existsEnv("GITHUB_ACTIONS"):
echo "travis_fold:start:" & desc.replace(" ", "_")
elif existsEnv("GITHUB_ACTIONS"):
echo "::group::" & desc echo "::group::" & desc
elif existsEnv("TF_BUILD"): elif existsEnv("TF_BUILD"):
echo "##[group]" & desc echo "##[group]" & desc
body body
if existsEnv("GITHUB_ACTIONS"):
if existsEnv("TRAVIS"):
echo "travis_fold:end:" & desc.replace(" ", "_")
elif existsEnv("GITHUB_ACTIONS"):
echo "::endgroup::" echo "::endgroup::"
elif existsEnv("TF_BUILD"): elif existsEnv("TF_BUILD"):
echo "##[endgroup]" echo "##[endgroup]"
proc execFold*(desc, cmd: string, errorcode: int = QuitFailure, additionalPath = "") = proc execFold*(desc, cmd: string, errorcode: int = QuitFailure, additionalPath = "") =
## Execute shell command. Add log folding for various CI services. ## Execute shell command. Add log folding for various CI services.
# https://github.com/travis-ci/travis-ci/issues/2285#issuecomment-42724719
let desc = if desc.len == 0: cmd else: desc let desc = if desc.len == 0: cmd else: desc
inFold(desc): inFold(desc):
exec(cmd, errorcode, additionalPath) exec(cmd, errorcode, additionalPath)