Skip to content

Change url for tag push events in chat message integration

Mats Estensen requested to merge matsest/gitlab:change-tag-url into master

What does this MR do?

Changes the url given in a chat message integration when a tag is pushed (tag push events).

The url is changed from #{project_url}/commits/#{ref} to #{project_url}/-/tags/#{ref} when the ref_type is tag. URL for other ref_type remains unchanged..

This is also reflected in the relevant test.

PS: This is my first MR in this repo, so please advise if I've missed some mandatory checks.

Why

Since tags in GitLab have a dedicated url, it makes more sense to link to the /-/tags/#{ref} than /commits/#{ref} for a tag push when displayed in a chat message. This would allow for the URL to direct the user to the tags view where release notes also are available.

Screenshots

N/A

Does this MR meet the acceptance criteria?

Conformity

Performance and Testing

Security

If this MR contains changes to processing or storing of credentials or tokens, authorization and authentication methods and other items described in the security review guidelines:

  • Label as security and @ mention @gitlab-com/gl-security/appsec
  • The MR includes necessary changes to maintain consistency between UI, API, email, or other methods
  • Security reports checked/validated by a reviewer from the AppSec team
Edited by Mats Estensen

Merge request reports