diff --git a/pyproject.toml b/pyproject.toml index 105bdbdf..19fd4464 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -4,11 +4,25 @@ build-backend = "pseudo_builder" [tool.release-gitter] git-url = "https://github.com/JohnnyMorganz/StyLua" -extract-files = ["stylua"] +extract-all = true format = "stylua-{system}-{arch}.zip" -exec = "chmod +x stylua" +exec = """python -c " +import os +import stat +import platform + +f = 'stylua' +s = platform.system() + +if s in ('Linux', 'Darwin') and os.path.exists(f): + current_mode = os.stat(f).st_mode + os.chmod(f, current_mode | stat.S_IEXEC) +" """ + [tool.release-gitter.map-arch] arm64 = "aarch64" +AMD64 = "x86_64" + [tool.release-gitter.map-system] Darwin = "macos" Windows = "windows"