Add --weekly flag to csv command
- Add `write_csv_weekly()` to output.py: writes entries from multiple days as a single CSV with one header row, correct date per row - Add `-w`/`--weekly` flag to csv subparser - _cmd_csv branches on args.weekly: fetches week sections, formats per-day date strings, calls write_csv_weekly; --raw is honoured - Add TestWriteCsvWeekly with 6 tests - Update README with weekly csv usage examples
This commit is contained in:
parent
985ee28113
commit
cd8ca789aa
4 changed files with 134 additions and 10 deletions
|
|
@ -67,6 +67,8 @@ uv run timesheets summary -w -ss --joplin # weekly totals only: one line
|
|||
uv run timesheets csv --joplin # stdout
|
||||
uv run timesheets csv --joplin -o output.csv # write to file
|
||||
uv run timesheets csv --raw --joplin # one row per entry, no aggregation
|
||||
uv run timesheets csv -w --joplin # full week
|
||||
uv run timesheets csv -w --raw --joplin # full week, no aggregation
|
||||
```
|
||||
|
||||
### stories
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue