Skip to content

implementation of a reporting feature and dry-run mode for the CLI#321

Open
monssefbaakka wants to merge 1 commit into
pashkov256:mainfrom
monssefbaakka:main
Open

implementation of a reporting feature and dry-run mode for the CLI#321
monssefbaakka wants to merge 1 commit into
pashkov256:mainfrom
monssefbaakka:main

Conversation

@monssefbaakka

Copy link
Copy Markdown

This PR introduces a reporting feature and a dry-run mode to the deletor CLI, enhancing its auditability and providing users with better control over file operations.

Key Changes:
CLI Flags: Added new flags: --report, --report-format, and --dry-run.
Reporting System: Implemented a reporting utility in internal/utils/report.go that supports exporting file actions to both JSON and CSV formats, including file paths, sizes (in bytes), and timestamps.
Dry-Run Mode: Added support for --dry-run, allowing users to see what actions would be taken without actually deleting or moving files.
Action Logging: Updated the CLI runner to collect report data for both files and empty folders, distinguishing between "taken" and "planned" actions.

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.

1 participant