-
Notifications
You must be signed in to change notification settings - Fork 57
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
cargo-dist include
directive _may_ be having problems archiving subdirectories?
#873
Comments
Wow, that's weird. I'm seeing the same thing with |
It looks like the tarballs are fine; only the zips are affected. I'm looking into the generation to identify the issue. |
Oh wow, thanks. I wanted to confirm, first, what's going on. Thank you a lot for looking into it. <3 |
ZIP expects unix-style paths here, and passing Windows paths will cause incorrect and broken files to be added to the directory. The `zip` crate's `start_file_from_path` and `add_directory_from_path` normalize these, but they were deprecated without replacement so we need to do the work ourselves. Fixes axodotdev/cargo-dist#873.
ZIP expects unix-style paths here, and passing Windows paths will cause incorrect and broken files to be added to the directory. The `zip` crate's `start_file_from_path` and `add_directory_from_path` normalize these, but they were deprecated without replacement so we need to do the work ourselves. Fixes axodotdev/cargo-dist#873.
Will this fix be released soon? My users are mostly on windows and the broken zip is pretty annoying. Thanks |
It's a holiday weekend at the moment, so I've been out of the office a little longer than usual. The next release will most likely be this coming week. |
No rush! Just wanted to confirm. Thanks. Happy Easter 😊 |
This fix is now available in the 0.12.1 bugfix release. |
Thanks a lot! |
I think there might still be an issue with sub directories. In my project I'm trying to include But instead of a subdirectory in Can look at the latest release of my repo to see the issue. It might be the way I'm including the paths actually. Should it "just work" to put the top most directory name? I'm specifying the sub directories and files. # Extra static files to include in each App (path relative to this Cargo.toml's dir)
include = ["./Config.toml", "./Arenas.ron", "./Commands.ron", "./Formulas.ron", "./PacketRateLimits.ron", "./db-init/", "./news.txt", "./lang/", "./maps/", "./pub/", "./pub/inns/", "./pub/npcs/", "./pub/items/", "./pub/shops/", "./pub/spells/", "./pub/classes/", "./pub/skill_masters/", "./quests/"] |
I'll test with that repo and see if I can identify the issue. Sorry about the inconvenience! |
I believe this should be fixed with the just-released 0.13.2; I tested with reoserv on Windows and the ZIP structure looks good to me now. Can you confirm if this is working for you now? |
Thanks! I'll test this soon |
@mistydemeo This is working now for me! thanks so much. Can close issue |
You're welcome! Glad it's working for you. |
I'm actually not sure, where the problem lies. I opened this issue with scoop first, because it got apparent when I extracted a cargo-dist packaged app: ScoopInstaller/Scoop#5845
But thinking about it, cargo-dist was zipping the file with the following
include
directive:So I wonder if there are some flags being used, that make it incompatible to be unpacked with 7-Zip?
A zip archive packed by cargo-dist like this:
is being extracted like this on Win11-x64 with 7-Zip: 23.01-x64
I'm talking about this archive: https://github.com/pace-rs/pace/releases/download/pace-rs-v0.15.1/pace-rs-x86_64-pc-windows-msvc.zip
I tried to get to the ground of it, but got lost in the Github Actions file. If you could direct to the root of this, I would be able to investigate further. Thank you!
The text was updated successfully, but these errors were encountered: