feat(jsonl): add omitempty to reduce JSONL bloat (beads-399)
Add omitempty JSON tags to Issue struct fields (Description, Status, Priority, IssueType) and SetDefaults method to apply proper defaults when importing JSONL with omitted fields. This reduces JSONL file size for minimal issues like notifications by not exporting empty/default values. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
@@ -953,6 +953,7 @@ func pruneExpiredTombstones(customTTL time.Duration) (*TombstonePruneResult, err
|
||||
// Skip corrupt lines
|
||||
continue
|
||||
}
|
||||
issue.SetDefaults() // Apply defaults for omitted fields (beads-399)
|
||||
allIssues = append(allIssues, &issue)
|
||||
}
|
||||
if err := file.Close(); err != nil {
|
||||
@@ -1049,6 +1050,7 @@ func previewPruneTombstones(customTTL time.Duration) (*TombstonePruneResult, err
|
||||
// Skip corrupt lines
|
||||
continue
|
||||
}
|
||||
issue.SetDefaults() // Apply defaults for omitted fields (beads-399)
|
||||
allIssues = append(allIssues, &issue)
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user