tweego
tweego copied to clipboard
Tweego binary does not have "executable" attribute in the release ZIP
$ wget -O tweego.zip https://github.com/tmedwards/tweego/releases/download/v2.1.1/tweego-2.1.1-linux-x64.zip
$ unzip tweego.zip
$ ls -l ✔ 6698 14:45:38
total 7732
-rw-r--r-- 1 username username 1341 Feb 24 2020 LICENSE
drwxr-xr-x 2 username username 140 Dec 23 2019 licenses
drwxr-xr-x 11 username username 220 Dec 23 2019 storyformats
-rw-r--r-- 1 username username 4506940 Feb 25 2020 tweego
-rw-r--r-- 1 username username 3107046 Feb 25 2020 tweego.zip
Have to apply chmod +x tweego
In general this is a limitation of the zip format as it stores extremely limited attributes about the original file (as it was originally only designed for MS-DOS file attributes). That said some zip programs allow storing some POSIX/Unix-style permissions in the optional extended attributes that can be saved in zip archives, however, how to set these and how compatible they are across zip clients is undefined (and so may not be compatible across different zip clients).
I am assuming @ezsh is using infozip. Using infozip one can query these extended attributes via unzip -Z tweego.zip
(-Z
causes infozip unzip
to act like infozip zipinfo
). This can be limited to specify files within the archive. As an example (and to keep from spamming lots of data here), executing unzip -Z tweego.zip tweego
to examine these extended attributes for only the tweego
executable within the released zip archive, I get:
-rw-a-- 6.3 fat 4506940 bx defN 20-Feb-25 01:09 tweego
It does not appear as if the released archives are storing such extended attribute information--or at least not in a format that infozip seems to understand.
If I use the infozip tools to unzip the archive, set the executable permission bit on the executable file and rezip the files, effectively recreating the zip archive, and then execute the same command, I now get:
-rwxr-xr-x 3.0 unx 4506940 bx defN 20-Feb-25 01:09 tweego
For reference if it matters, I am using infozip tools from/on Ubuntu focal in WSL2 on Windows 10.
If this is a concern for the tweego release process, I recommend switching the POSIX/Unix binary releases to different archive formats (e.g., a compressed tar archive, etc.).
I also noticed this on macOS (12.6) with tweego 2.1.1 (64bit). I don't recall having the problem with previous versions of tweego, but it's been a while since I installed one. I also don't have a general issue with executables unzipping to non-executables; this is the first time I've seen it.