Issues
Configuring issues per repository
4 min read
Each repository has its own issue rules: where the issues come from, what the working branch is called and how the issue is referenced in the commit. All of this is in Preferences › Issues, in the group for the repository in the active tab. The Jira connection, in the same place, applies to all repositories and has its own page: Connecting Jira.
- Preferences (Ctrl+,) › Issues › In this repository app group.
- Palette (Ctrl+P): "Preferences: issues (Jira, branch name template, commit reference)".
- In the notices of the ISSUES section, the Preferences › Issues button.
Without an open repository, the group shows "Open a repository to set the issue source, the branch name template and the commit reference."
Changes take effect right away. The text fields save when you leave the field or press Enter.
| Option | What it does | Default |
|---|---|---|
| Issue source | Where this repository's issues come from. | Automatic |
| Jira project | The project key in Jira (e.g., PROJ). | empty |
| Branch name template | The name suggested in "Start work". | feature/{number}-{title} (Jira: feature/{key}-{title}) |
| In-progress label | The label added to the GitLab/GitHub issue when you start work. | Doing |
| Reference in the commit message | The format and the place of the issue reference in the commit. | Closes #123 at the end of the description (Jira: PROJ-123 at the start of the summary) |
| Option | When to use it |
|---|---|
| Automatic (Jira if there's a project key; otherwise the remote's GitLab/GitHub) | The common case. Just enter the Jira project to switch the source. |
| The remote's GitLab/GitHub | To use the server's issues even with a Jira key filled in. |
| Jira | To use Jira; requires the Jira connection and the project. |
| None (hide issues) | Removes the ISSUES section, the branch's issue bar and the commit reference in this repository. |
The hint next to it says what applies right now: "Now: issues from GitLab.", "Now: issues from Jira (project PROJ)." or "Now: no issues in this repository." When something is missing, it shows the reason (for example, "Enter this repository's Jira project key in Preferences › Issues.").
The project key, in uppercase (the app converts it). Besides choosing the project for the issue
list, it's used to recognize the issue in branches that only have the number (feature/123-…
becomes PROJ-123).
The Verify button (tooltip "Check the key in Jira") queries Jira and shows the project's key and name, for example "PROJ: Customer portal". It only works with the Jira connection set up (otherwise, the tooltip says "Set up the Jira connection above").
The accepted fields are {type}, {number}, {key} and {title} (the title goes in lowercase,
without accents, up to 50 characters). The Portuguese and Spanish field names work too: {tipo},
{numero}, {chave} and {titulo} in Portuguese, and {clave} in Spanish (the others are the
same as in Portuguese). The field's hint says so: "The Portuguese and Spanish field names work too."
The screen shows the names in the interface language, but a saved template isn't rewritten when the
language changes: it keeps working as you typed it. With Gitflow initialized, the feature/ at the
start of the template becomes Gitflow's feature prefix. An empty field goes back to the source's
default, shown with the interface language's names.
Below the field there's an example with the current template, computed for the issue #123 (or
PROJ-123) with the title "Fix login form validation".
Template examples:
| Template | Issue | Branch |
|---|---|---|
feature/{number}-{title} | #123 Fix login | feature/123-fix-login |
{type}/{number}-{title} | #123, type Bug | bug/123-fix-login |
feature/{key}-{title} | PROJ-123 Fix login | feature/PROJ-123-fix-login |
{key} | PROJ-123 | PROJ-123 |
The details of how the name is put together are in Starting work on an issue.
The label that Mark as in progress with the label adds to the issue, on GitLab and GitHub. Use
the label your team uses on the board (for example, Doing or In Progress). Jira has no label:
the transition is chosen at that moment, in the dialog itself.
Two selectors, side by side:
- the first one sets the format: Default (with the source's format in parentheses, such as
"Default (Closes #123)"),
Closes #123,Refs #123or just the key (#123). - the second one sets where the reference goes: Default (with the source's place in parentheses), At the start of the summary or At the end of the description.
The hint shows how it turns out, for example: "The commit box button (and Alt+I) adds Closes #123 at the end of the description. "Closes" closes the issue when the commit reaches the default branch."
Nothing: these preferences stay in Versora (in the app's storage, per repository). They don't go
into .git/config or into project files, and they don't apply to other people on the team.
Set the option back to its previous value. For the template, clear the field to go back to the default.