Skip to content
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

GZip without TAR #14

Open
richardgavel opened this issue Mar 13, 2018 · 7 comments
Open

GZip without TAR #14

richardgavel opened this issue Mar 13, 2018 · 7 comments

Comments

@richardgavel
Copy link

I was struggling with why my GZIP wasn't working as expected until I read the source code and realized you both TAR AND GZIP the files. The problem is my files are already in a TAR (It's a save of a Docker image, which is output as a TAR). Seems kinda of weird that you do both by default. Is there a way to allow GZIP without TAR? I know doing this by default would be a breaking change.

@akordowski
Copy link
Owner

@richardgavel I'm sorry you facing issues with the AddIn. I created the combined way to provide a convinent way to create a GZip archive. But looking at your case, that was not so smart. Unfortunatly I can't provide at the moment a quick solution for your issue. I have to look deeper at it .

@richardgavel
Copy link
Author

At the moment, it was quickest to just call 7zip.exe, so I'm not blocked. I know I could have also done the C# code to GZIP it too and probably will.

@akordowski
Copy link
Owner

Glad to hear you have found a solution. But anyway, thank you for the hint and I will try to solve the issue.

@richardgavel
Copy link
Author

richardgavel commented Mar 14, 2018

One option, there technically is no overload of the GZipCompress alias that takes in a single FilePath as the input. I had to use the IEnumerable with one entry. You could that alias and skip the TAR if the single FilePath is a TAR file (Or just fail if not a TAR file)...Anytime you're specifying more than one file, by definition those files could still be TARred together.

@akordowski
Copy link
Owner

Yes, I had also the idea. But the Uncompres() method would be not the same, because there I can't determine if the archive contains a Tar file. But if it were a help for you I could implement the workaround.

@richardgavel
Copy link
Author

richardgavel commented Mar 14, 2018 via email

@PulsarFX
Copy link

This behaviour drove me nuts for some time. I have the same use case as the topic starter: gzip a docker tar output.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants