Skip to content

Create a release from existing tag on the New Release page

Problem to solve

As a user, I want be able to create a release from an existing tag, so I can have more flexibility when planning releases.

Intended users

User experience goal

The New Release page only support creating a new release based on a new tag. Users will also be able to create a new release associated to an existing tag via UI.

Proposal

🔮 SEE PROTOTYPE ON FIGMA

  • In the Create/Edit Release forms, users should be able to select an existing tag.
  • The New tag field gets updated from a simple input field to a dropdown select, to follow the same standard used in the milestone select, as well as other forms in GitLab.
    • frontend : make an update to the replace the existing component in the page
    • The component behaves similar to the milestones field, and the field environment scope in -/settings/ci_cd > Variables.
  • User can select from existing tags, search existing tags, or click the option to create a new one.
  • Tags that are already associated to a release are not displayed in the list.
  • When an existing tag is selected, the Create from input gets disabled in the UI. The user cannot select or interact with the component.
  • When editing a Release, user should be able to interact with the dropdown and select a different tag.
  • Only 1 (one) tag can be selected at a time.
  • The field is mandatory.

Component behaviour

  • When user clicks the trigger, a drop down opens. The footer displays the option Manage tags, which should open the Tags overview page.
  • When there's no tags to be displayed: When no tags exist in the project/group, the dropdown display only the Manage tags options.
  • When tags exist: the dropdown displays a list of tags, ordered alphabetically. No item is pre-selected in the list. Clicking a tag show mark it as selected and close the dropdown.
  • Autocomplete results: User can type in a tag name in the search field. The matching result is displayed. Clicking a tag should mark it as selected and close the dropdown.
  • No matching results: User type in a tag name in the search field but no results can be found. An empty state message is shown.
    • The Create new option is shown in the footer of the dropdown.
    • Clicking Create new closes the dropdown and the option is marked as selected.
  • Changing selection: Opening the dropdown shows the selected (checked) option. User can select another tag, which will deselect the previous option.

Further details

This work will require no backend work; the Release API already includes functionality to create a release based on a new tag or an existing tag.

A prerequisite to implementing this feature it to update the ref selector component to accept a configuration that limits the type of ref it searches. Right now, it always searches branches, tags, and commits. For this feature, we will need this dropdown to only search tags. This work should be completed in a separate MR.

One technical consideration: the form that powers the New Release page is shared by the Edit Release page. Ideally, we should design this new feature in such a way that it also allows an existing release to have its tag edited (to be set to either a new tag or a different existing tag). However, this isn't a requirement of this feature and we should skip this if it complicates things.

Permissions and Security

  • Add expected impact to members with no access (0)
  • Add expected impact to Guest (10) members
  • Add expected impact to Reporter (20) members
  • Add expected impact to Developer (30) members
  • Add expected impact to Maintainer (40) members
  • Add expected impact to Owner (50) members

Documentation

Yes, this will require an update to the Releases documentation.

Availability & Testing

This feature should be developed behind a new feature flag: new_release_existing_tag

What does success look like, and how can we measure that?

Customers will have the ability to select an existing tag when creating a new release.

What is the type of buyer?

Is this a cross-stage feature?

No.

Links / references

Click this to collapse/fold initial proposal. Manual selection option
Edited by Dan Davison