Commit Graph

3 Commits

Author SHA1 Message Date
BeauTroll
07a98d5617 Fix duplicate output in disk-usage script with awk
Some checks failed
Deploy Borgmatic Configuration / Deploy to Production Server (push) Has been cancelled
Replace grep-based parsing with awk to properly capture header and data
lines without duplicates.

Changes:
- Use awk to capture header line (Original/Compressed/Deduplicated size)
- Print header followed by matching "All archives" line with sizes
- Exit immediately after first match to prevent duplicates

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2025-12-18 16:09:56 +01:00
BeauTroll
b816e25caa Add column headers to disk-usage output
Some checks failed
Deploy Borgmatic Configuration / Deploy to Production Server (push) Has been cancelled
Include the column headers (Original size, Compressed size, Deduplicated size)
in the disk-usage output for better readability.

Changes:
- Use grep -B1 to capture header line before "All archives"
- Display both header and data lines

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2025-12-18 16:07:51 +01:00
BeauTroll
9a5ea36901 Refactor disk-usage logic into dedicated script
Some checks failed
Deploy Borgmatic Configuration / Deploy to Production Server (push) Has been cancelled
Move disk-usage functionality from Makefile to a dedicated shell script
for better maintainability and consistency with other scripts.

Changes:
- Create scripts/disk-usage.sh with all disk usage logic
- Simplify Makefile disk-usage target to call the script
- Add environment loading and color formatting to script
- Fix duplicate output by adding head -1 to grep chain

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2025-12-18 16:05:58 +01:00