-
Notifications
You must be signed in to change notification settings - Fork 17
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
Convenience functions for dealing with .gz files #12
Conversation
Convenience functions to read/write directly from/to a named file. I'm doing a cleanup of my local stash of convenience functions and thought that these might be generally useful. ```julia gzwrite("/tmp/foo.gz", "hello") gzreadall("/tmp/foo.gz") "hello" ```
Current coverage is
|
You can't export the same names from multiple packages. |
Hi @tkelman, re name clash across packages: @kmsquire suggested that Gzip.jl is depricated-ish in favour of Libz.jl, so I move the PR over to here. More generally though, I imagine that its a useful pattern to have the same names from multiple packages if they really do the same thing. That would allow easy plug ability of alternate implementations. |
Except that packages aren't always exactly drop in replacements (if they were they'd just be new versions instead of separate packages), and different downstream users have different requirements, including the ability to use both simultaneously. |
If you want to extend the same generic function with new methods that makes complete sense, but you have to agree where the generic function is defined and extended from, and use completely disjoint type signatures for all methods. |
bump JuliaLang/julia#14660 is now merged This PR makes the gz interface more consistent with ::IO is base. |
Awesome! Is there any chance of increasing the code coverage a bit before a merge? codecov is telling me it has fallen as a result of the PR. |
done |
@samoconnor that was fast! if CI checks pass, LGTM |
Only appveyor fails, but it was failing before. I don't think it's a PR specific failing. |
Convenience functions for dealing with .gz files
Update README.md with examples per #12
Convenience functions to read/write directly from/to a named file.
I'm doing a cleanup of my local stash of convenience functions and thought that these might be generally useful.
See also JuliaIO/GZip.jl#45 (comment)
Also, the example in README.md doesn't work...
The underlying file needs to be closed to ensure that the file is completely written...
The
gzopen(::Function...)
methods in the PR make this easier by supportinggzopen("foo.gz") do io...
syntax.