Skip to content

create tarball of output files in output directory#360

Merged
harp-intel merged 5 commits into
mainfrom
tarball
Jun 4, 2025
Merged

create tarball of output files in output directory#360
harp-intel merged 5 commits into
mainfrom
tarball

Conversation

@harp-intel
Copy link
Copy Markdown
Contributor

@harp-intel harp-intel commented Jun 3, 2025

For all commands except Metrics, this PR creates a tarball, when in debug mode, that contains the generated raw files, report files, and the log file.

Signed-off-by: Harper, Jason M <jason.m.harper@intel.com>
@harp-intel harp-intel requested a review from Copilot June 3, 2025 23:08

This comment was marked as outdated.

harp-intel and others added 3 commits June 3, 2025 16:12
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Signed-off-by: Harper, Jason M <jason.m.harper@intel.com>
@harp-intel harp-intel requested a review from Copilot June 4, 2025 13:51
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR introduces functionality to create a tarball (TGZ) of generated output files—raw files, report files, and the log file—for non-Metrics commands. It also adds corresponding tests and integrates the tarball creation into the application context when debugging is enabled.

  • Added CreateFlatTGZ function in util.go to generate a flat tarball.
  • Extended tests in util_test.go to cover both success and failure scenarios.
  • Updated application context and startup logic in common.go and cmd/root.go to support tarball generation.

Reviewed Changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated 2 comments.

File Description
internal/util/util_test.go Added tests for CreateFlatTGZ functionality.
internal/util/util.go Implemented CreateFlatTGZ for creating a flat tarball.
internal/common/common.go Integrated tgz archive creation when debugging is enabled.
cmd/root.go Updated timestamp usage and log file handling in app init.

Comment thread internal/util/util.go
Comment thread cmd/root.go
@harp-intel harp-intel merged commit d77c6d2 into main Jun 4, 2025
2 checks passed
@harp-intel harp-intel deleted the tarball branch June 4, 2025 20:51
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

Successfully merging this pull request may close these issues.

2 participants