Skip to content

Commit ebd8a6c

Browse files
Matthieu Ciapparaclaude
andcommitted
fix: display comments in chronological order
The GitLab API returns issue notes sorted by created_at descending by default. Explicitly request ascending order so comments appear oldest first, matching the natural reading order. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
1 parent 61acfa3 commit ebd8a6c

2 files changed

Lines changed: 5 additions & 1 deletion

File tree

CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,10 @@
22

33
## [Unreleased]
44

5+
### Fixed
6+
7+
- Comments are now displayed in chronological order (oldest first) instead of reverse.
8+
59
## [0.1.0] - 2026-04-10
610

711
### Added

bin/issue-md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -220,7 +220,7 @@ module IssueFormatter
220220
end
221221

222222
def append_comments(lines, client, project_path, issue_iid, img_opts)
223-
notes = client.issue_notes(project_path, issue_iid, per_page: 100)
223+
notes = client.issue_notes(project_path, issue_iid, per_page: 100, order_by: 'created_at', sort: 'asc')
224224
user_notes = notes.reject(&:system)
225225
return unless user_notes.any?
226226

0 commit comments

Comments
 (0)