feat(vc): browse-at-remote: recognize gitlab.* hosts

Previously, only gitlab.com and gitlab.gnome.org were recognized as
gitlab hosts. This tweaks browse-at-remote to recognize any subdomain
named gitlab.* as a gitlab host (as a fallback, if no other regexp
matches).
This commit is contained in:
Henrik Lissner 2023-07-24 02:47:55 +02:00
parent f0b58fc452
commit 98f3af7a7c
No known key found for this signature in database
GPG key ID: B60957CA074D39A3

View file

@ -136,6 +136,10 @@ otherwise in default state."
;; Add codeberg.org support
;; TODO: PR this upstream?
(add-to-list 'browse-at-remote-remote-type-regexps '(:host "^codeberg\\.org$" :type "codeberg"))
;; Expand recognition for gitlab hosts besides gitlab.org or gitlab.gnome.org
;; which are presumably hosted in a gitlab.* subdomain.
;; TODO: PR this upstream?
(add-to-list 'browse-at-remote-remote-type-regexps '(:host "^gitlab\\." :type "gitlab") 'append)
;; HACK `browse-at-remote' produces urls with `nil' in them, when the repo is
;; detached. This creates broken links. I think it is more sensible to