-
-
Notifications
You must be signed in to change notification settings - Fork 102
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
cmd/note-common.go: Fix context comments on diffs
krobelus noticed that it wasnt possible to comment on the context portion of a diff. For example, when commenting on line 6 of | newfile: Makefile oldfile: Makefile | @@ -5,6 +5,8 @@ SUBLEVEL = 0 | 5 5 EXTRAVERSION = | 6 6 NAME = Merciless Moray | 7 7 | 8 +# space | 9 + | 8 10 # | 9 11 # DRM backport version | 10 12 # it was not possible to comment on line 6 and lab would output an error. This is fixed by reworking the code to detect context diffs, however, this only appears to work on code shown before the difflines. There are several open GitLab API issues that report errors when commenting on Merge Request commits and it is likely that one of these is causing the error. ex) https://gitlab.com/gitlab-org/gitlab-foss/-/issues/28599 Rework and cleanup the code to allow for commenting on the context of diffs. Signed-off-by: Prarit Bhargava <prarit@redhat.com>
- Loading branch information
Showing
2 changed files
with
101 additions
and
50 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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