feat: Add group_by parameter for grouping revisions#7
Merged
Conversation
0aef0cc to
199ad1d
Compare
Add group_by parameter to load_extra('recentupdate') and
recentupdate_group_by config value (ENUM: day/month/year) for
grouping revisions by UTC time period and author.
Key changes:
- Refactor get_git_revisions to yield revisions as an Iterator
- Add streaming group logic: groups are built incrementally and
compacted only when count is reached, ensuring exact count output
- Files merged with dedup, priority: removed > added > changed
- Messages merged in chronological order (oldest first)
Co-authored-by: MiMoCode <mimo@xiaomi.com>
199ad1d to
78882c8
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
group_byparameter toload_extra('recentupdate')for grouping revisions by time periodrecentupdate_group_byconfig value with ENUM constraint (day/month/year)get_time_period_key,compact_revision,group_revisionsfunctionsChanges
src/sphinxnotes/recentupdate/__init__.py: Add grouping logic and config valuedocs/usage.rst: Documentgroup_byparameter and add exampledocs/conf.rst: Documentrecentupdate_group_byconfig valuetests/test_group_revisions.py: Add unit tests for new functionsCo-authored-by: MiMoCode mimo@xiaomi.com