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

temporarily extract compressed archive files (.tar.gz, .tar.xz, etc.) #298

Open
jtmoon79 opened this issue Jun 1, 2024 · 0 comments
Open
Labels
difficult A difficult problem; a major coding effort or difficult algorithm to perfect enhancement New feature or request P1 important

Comments

@jtmoon79
Copy link
Owner

jtmoon79 commented Jun 1, 2024

Summary

With #284 it is now pretty easy to extract a compressed file to a temporary file. So automatically handle compressed archive files, e.g. logs.tar.gz, etc.

Current behavior

Given a gzipped tar file dtf2-2_dtf3-1.tar.gz

$ s4 /tmp/dtf2-2_dtf3-1.tar.gz
ERROR: other error: failed to read entire block for file "/tmp/dtf2-2_dtf3-1.tar.gz"

Using s4 0.7.72

Suggested behavior

  1. for some file that is file.tar.ZZ where .ZZ is some compression name, .gz, .xz etc.
  2. extract file.tar to a temporary directory
  3. process file.tar using function process_tar

Setting the file path for display in -p and --summary will require some minor refactoring.

@jtmoon79 jtmoon79 added enhancement New feature or request P1 important difficult A difficult problem; a major coding effort or difficult algorithm to perfect labels Jun 3, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
difficult A difficult problem; a major coding effort or difficult algorithm to perfect enhancement New feature or request P1 important
Projects
None yet
Development

No branches or pull requests

1 participant