diff options
| author | Paul Buetow <paul@buetow.org> | 2025-06-28 14:22:57 +0300 |
|---|---|---|
| committer | Paul Buetow <paul@buetow.org> | 2025-06-28 14:22:57 +0300 |
| commit | 57e433ade2e450ebaab1efeef34bd0f02823f2e9 (patch) | |
| tree | cdb0ebd2ad92283810363516da35b16e7f9eb765 /internal/task | |
| parent | 1d4ab9102d46f9f1f41946aa600a1404f54696f9 (diff) | |
feat: add project field support to TaskSamurai
Add comprehensive project field support including:
- Project column in table view with automatic width calculation
- 'J' hotkey to edit project in both table and detail views
- Project field in task detail view (between Start and Entry)
- Search functionality includes project names
- Enter key on project column allows inline editing
The project field integrates seamlessly with Taskwarrior's native
project support and follows the same UI patterns as other editable
fields in the application.
🤖 Generated with [Claude Code](https://claude.ai/code)
Co-Authored-By: Claude <noreply@anthropic.com>
Diffstat (limited to 'internal/task')
| -rw-r--r-- | internal/task/task.go | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/internal/task/task.go b/internal/task/task.go index 86c93f4..2c7f8e8 100644 --- a/internal/task/task.go +++ b/internal/task/task.go @@ -26,6 +26,7 @@ type Task struct { ID int `json:"id"` UUID string `json:"uuid"` Description string `json:"description"` + Project string `json:"project"` Tags []string `json:"tags"` Status string `json:"status"` Start string `json:"start"` @@ -298,6 +299,11 @@ func SetDescription(id int, desc string) error { return modifyTask(id, "description:"+desc) } +// SetProject changes the project of the task with the given id. +func SetProject(id int, project string) error { + return modifyTask(id, "project:"+project) +} + // Annotate adds an annotation to the task with the given id. func Annotate(id int, text string) error { if id <= 0 { |
