deploy-workflow: create docker compose file
Gitea Actions Demo / Explore-Gitea-Actions (push) Successful in 6s

This commit is contained in:
2026-07-04 01:44:33 +03:00
parent 457bf8e586
commit 0dd86c53dd
@@ -25,12 +25,22 @@ runs:
raw_text = os.environ.get("RAW_MESSAGE", "") raw_text = os.environ.get("RAW_MESSAGE", "")
output_file = os.environ.get("ESCAPED_MESSAGE") output_file = os.environ.get("ESCAPED_MESSAGE")
escape_chars = ["-", ".", "!"] def escape_text(text):
escaped_text = raw_text escape_chars = ["-", ".", "!"]
for char in escape_chars: for char in escape_chars:
escaped_text = escaped_text.replace(char, f"\\{char}") text = text.replace(char, f"\\{char}")
return text
escaped_text = escaped_text.replace("`", "\\`") parts = raw_text.split("`")
processed_parts = []
for i, part in enumerate(parts):
if i % 2 == 0:
processed_parts.append(escape_text(part))
else:
processed_parts.append(f"\\`{part}\\`")
escaped_text = "".join(processed_parts)
with open(output_file, "a", encoding="utf-8") as f: with open(output_file, "a", encoding="utf-8") as f:
f.write("result<<EOF\n") f.write("result<<EOF\n")