Skip to main content

Configuring autolinks to reference external resources

You can add autolinks to external resources like JIRA issues and Zendesk tickets to help streamline your workflow.

Os links automáticos estão disponíveis em repositórios com o GitHub Pro, o GitHub Team, o GitHub Enterprise Cloud, e o GitHub Enterprise Server. Para obter mais informações, confira "produtos de GitHub".

Anyone with admin permissions to a repository can configure autolink references to link issues, pull requests, commit messages, and release descriptions to external third-party services.

Autolink references can now accept alphanumeric characters. When originally introduced, custom autolinks were limited to external resources that used numeric identifiers. Custom autolinks now work with alphanumeric and numeric identifiers.

You define custom autolinks by specifying a reference prefix and a target URL.

  • Reference prefixes cannot have overlapping names. For example, a repository cannot have two custom autolinks with prefixes such as TICKET and TICK, since both prefixes would match the string TICKET123a.
  • Target URLs include a <num> variable which represents the reference identifier of the linked resource.

This procedure demonstrates how to configure autolinks to reference external resources. For example, if you use Zendesk to track user-reported tickets, you can reference a ticket number in the pull request you opened to fix the issue.

  1. No GitHub.com, navegue até a página principal do repositório.

  2. Abaixo do nome do repositório, clique em Configurações. Botão Configurações do repositório

  3. In the "Integrations" section of the sidebar, click Autolink references.

  4. Click Add autolink reference. Button to fill out autolink reference information.

  5. Select the format of the reference identifier used in the external resource, either alphanumeric or numeric. Autolink format setting, alphanumeric or numeric.

  6. Under "Reference prefix", type a short, meaningful prefix you want collaborators to use to generate autolinks for the external resource. Field to type abbreviation for external system.

  7. Under "Target URL", type the link to the external system you want to link to. Use the <num> variable as a placeholder for the reference identifier. Field to type URL to external system.

  8. Click Add autolink reference.