Skip to content

Automatic ticket links #489

@woodsae

Description

@woodsae

It is a common practice that developers put their ticket number at the beginning of their commits and pull requests. These ticket numbers then appear in the changelog, but as plain text. It would be helpful if the changelog generator could do a regex for the ticket number pattern and replace it with a link to the ticket in the project management tool of your choice.

I envision this working by passing the following command line arguments:

  • --ticket-url
  • --ticket-pattern

Here is how I'm currently implementing this in Travis without the feature in place:

github_changelog_generator --between-tags ${TRAVIS_TAG} --no-unreleased -t ${GITHUB_OAUTH_TOKEN} --no-verbose -o '/tmp/release-notes.txt'

perl -i -pe 's#([A-Z]{2,}-\d+)#[$1](https://example.atlassian.net/browse/$1)#g' /tmp/release-notes.txt

This transforms something like [PROJ-123] into a link directly to JIRA.

This works well because the ticket number is directly in the URL instead of an ID, which could be problematic in other ticket management tools.

Here is how I would like to see it work:

github_changelog_generator --between-tags ${TRAVIS_TAG} --no-unreleased -t ${GITHUB_OAUTH_TOKEN} --no-verbose --ticket-url 'https://example.atlassian.net/browse/$1' --ticket-pattern '([A-Z]{2,}-\d+)' -o '/tmp/release-notes.txt'

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      pFad - Phonifier reborn

      Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

      Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


      Alternative Proxies:

      Alternative Proxy

      pFad Proxy

      pFad v3 Proxy

      pFad v4 Proxy