Skip to content

v1.6.0 - Inline MR Diff Comment Documentation & Script

Choose a tag to compare

@vince-winkintel vince-winkintel released this 03 Mar 15:57
· 59 commits to main since this release
efabfbc

What's New

glab-mr/SKILL.md — New Section: Posting Inline Comments on MR Diffs

  • Documents why glab api --field silently fails for inline comments (falls back to general comments)
  • Full Python code example using urllib + JSON body for correct inline posting
  • Line number parsing helper (diff hunk parser)
  • Batch script usage reference

scripts/post-inline-comment.py (New)

  • Supports single comment (--file, --line, --body) and batch mode (--batch comments.json)
  • Auto-reads GitLab token from glab config — no env var needed
  • Always fetches fresh SHAs from /versions endpoint to avoid stale commit issues
  • Reports inline vs. general fallback per comment with clear output
  • stdlib only — no pip installs required