Skip to content

Commit 5a9152d

Browse files
authored
fix(release-gitter): correct Windows asset name for pip build (#1018)
* Switch to extract-all for release-gitter and fix architecture mapping - Replaced `extract-files` with `extract-all = true` for automatic extraction - Added `AMD64 = "x86_64"` mapping for release-gitter - Removed chmod command for Windows compatibility * fix(build): set StyLua binary executable on Unix via Python exec
1 parent 7e19753 commit 5a9152d

File tree

1 file changed

+16
-2
lines changed

1 file changed

+16
-2
lines changed

pyproject.toml

Lines changed: 16 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,25 @@ build-backend = "pseudo_builder"
44

55
[tool.release-gitter]
66
git-url = "https://github.com/JohnnyMorganz/StyLua"
7-
extract-files = ["stylua"]
7+
extract-all = true
88
format = "stylua-{system}-{arch}.zip"
9-
exec = "chmod +x stylua"
9+
exec = """python -c "
10+
import os
11+
import stat
12+
import platform
13+
14+
f = 'stylua'
15+
s = platform.system()
16+
17+
if s in ('Linux', 'Darwin') and os.path.exists(f):
18+
current_mode = os.stat(f).st_mode
19+
os.chmod(f, current_mode | stat.S_IEXEC)
20+
" """
21+
1022
[tool.release-gitter.map-arch]
1123
arm64 = "aarch64"
24+
AMD64 = "x86_64"
25+
1226
[tool.release-gitter.map-system]
1327
Darwin = "macos"
1428
Windows = "windows"

0 commit comments

Comments
 (0)