FS#43290 - aur4 allow comments to reference (link) git commits

Attached to Project: AUR web interface
Opened by Ido Rosen (idorosen) - Thursday, 01 January 2015, 09:22 GMT
Last edited by Eli Schwartz (eschwartz) - Monday, 06 November 2017, 16:31 GMT
Task Type Feature Request
Category Backend
Status Closed
Assigned To Lukas Fleischer (lfleischer)
Architecture All
Severity Low
Priority Normal
Reported Version 3.5.0
Due in Version 4.6.0
Due Date Undecided
Percent Complete 100%
Votes 2
Private No

Details

4) Allow commenters to reference commit SHAs (and convert those to
links) in the comments section, e.g. gitlab uses ! then the first 7 or
more characters of commit sha.

This task depends upon

Closed by  Eli Schwartz (eschwartz)
Monday, 06 November 2017, 16:31 GMT
Reason for closing:  Fixed
Additional comments about closing:  https://git.archlinux.org/aurweb.git/com mit/?id=bb623fc545f0e0187cc9b32386c383b7 32bcc9ae
Comment by Thiago Perrotta (thiagowfx) - Thursday, 18 June 2015, 05:57 GMT
Can people see the git history tree of a specific PKGBUILD? I mean, see without cloning the git repository: on the web? If not, then I believe this feature would not be much useful.
Comment by Johannes Löthberg (demize) - Thursday, 18 June 2015, 07:37 GMT
This should be rather simple to implement in theory, though would require parsing comments. Hmm.

@thiagowfx: See the View PKGBUILD and View Changes links in the AUR4.
Comment by Pablo Lezaeta (Jristz) - Wednesday, 24 June 2015, 19:05 GMT
One user can comment that commit xyz123asd098 broke the package but previous are correct, so a maintainer could have a starting point to know that when the package was broken.
Comment by Ian D. Scott (ids1024) - Sunday, 11 October 2015, 19:01 GMT
@Kyrias Aren't comments already parsed for urls? This would be fairly similar.
Comment by Johannes Löthberg (demize) - Monday, 12 October 2015, 17:27 GMT
Well, there's a regex match for a subset of URLs, yeah, but there are some other issues, biggest of which is, how do you determine when to generate a link?

You can't really just link anything that is a SHA-1 hash, because it could mean practically anything, and many times wouldn't be related to a commit in the repo of the package you're commenting on.

So, to do it robustly would probably require some custom syntax for it, which Lukas is against adding.
Comment by Ian D. Scott (ids1024) - Monday, 12 October 2015, 22:24 GMT
If it could check the git log, then it could only link them if there is a commit with that sha1. But I suppose the commit log is probably not currently available to the php code for the aur, is it?
Comment by Mark Weiman (markzz) - Sunday, 13 March 2016, 21:06 GMT
What about adding a marker like an exclaimation mark (!) to reference a commit?

For example, if I wanted to reference commit 12345678, I would type !12345678 in my comment.

Oh wait, I'm dumb and didn't notice the person who filed this already suggested this....

Loading...