draft_month
Drafts a read-only monthly timesheet from git commit messages into a JSON file, maps weekday commits to 8-hour entries, and returns gaps for review before applying.
Instructions
Draft a timesheet from git commit messages (read-only, touches no eHour page). One entry per weekday in the range, 8h each: "[8] TICKET: Title" then " - bullet" lines from the commit subjects, ASCII-only. Weekend commits move to the nearest empty weekday. Writes the entries JSON to file and returns only a summary { file, days: [{ date, tickets, chars }], moved, gaps }. Read the file, shorten each comment to 1-3 outcome bullets per ticket, fill every gap (a gap has an empty comment and is rejected by apply_month), then show the month to the user.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"from": "<from>",
"to": "<to>"
},
"name": "draft_month"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| to | Yes | ||
| from | Yes | ||
| repo | No | Git repository to read; defaults to gitRepo from ehour.config.json. | |
| author | No | git --author filter; defaults to the repo user.name. | |
| outFile | No | Where to write the draft; defaults to drafts/<from>_<to>.json in this repo. |