From 315a7ea8c174e094c0e23b15a1ae3d46fb6d379f Mon Sep 17 00:00:00 2001 From: Igor Bari Date: Mon, 11 Mar 2024 19:29:19 +0000 Subject: [PATCH] write to GITHUB_OUTPUT --- src/github_utils.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/github_utils.py b/src/github_utils.py index 3baf7d3..fe407d6 100644 --- a/src/github_utils.py +++ b/src/github_utils.py @@ -104,4 +104,5 @@ def create_pages_artifact( run(["chmod", "-c", "-R", "+rX", directory]) run(["tar", "--dereference", "--hard-dereference", "--directory", directory, "-cvf", tar_file, "."]) - run(["echo", f"artifact={tar_file}", ">>", environ.get("GITHUB_OUTPUT")]) + with open(environ.get("GITHUB_OUTPUT"), 'a') as output: + output.write(f"artifact={tar_file}")