Commit 55d9f168 authored by Nick Thomas's avatar Nick Thomas

Remove the global default branch feature flag

This has been enabled by default for a number of releases now. Time for
it to go.
parent 2c214499
......@@ -2,8 +2,7 @@
- page_title _("Repository")
- @content_class = "limit-container-width" unless fluid_layout
- if Feature.enabled?(:global_default_branch_name, default_enabled: true)
%section.settings.as-default-branch-name.no-animate#js-default-branch-name{ class: ('expanded' if expanded_by_default?) }
%section.settings.as-default-branch-name.no-animate#js-default-branch-name{ class: ('expanded' if expanded_by_default?) }
.settings-header
%h4
= _('Default initial branch name')
......
---
title: Remove the global default branch feature flag
merge_request: 59024
author:
type: other
---
name: global_default_branch_name
introduced_by_url: https://gitlab.com/gitlab-org/gitlab/-/merge_requests/35269
rollout_issue_url:
milestone: '13.2'
type: development
group: group::source code
default_enabled: true
......@@ -60,7 +60,6 @@ GitLab administrators can configure a new default branch name at the
> - It's deployed behind a feature flag, enabled by default.
> - It cannot be enabled or disabled per-project.
> - It's recommended for production use.
> - For GitLab self-managed instances, GitLab administrators can opt to [disable it](#enable-or-disable-custom-initial-branch-name).
GitLab [administrators](../../../permissions.md) of self-managed instances can
customize the initial branch for projects hosted on that instance. Individual
......@@ -75,25 +74,6 @@ Projects created on this instance after you change the setting use the
custom branch name, unless a group-level or subgroup-level configuration
overrides it.
#### Enable or disable custom initial branch name **(FREE SELF)**
Setting the default initial branch name is under development but ready for production use.
It is deployed behind a feature flag that is **enabled by default**.
[GitLab administrators with access to the GitLab Rails console](../../../../administration/feature_flags.md)
can opt to disable it for your instance.
To disable it:
```ruby
Feature.disable(:global_default_branch_name)
```
To enable it:
```ruby
Feature.enable(:global_default_branch_name)
```
### Group-level custom initial branch name **(FREE)**
> - [Introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/221014) in GitLab 13.6.
......
......@@ -12,23 +12,6 @@ RSpec.describe 'admin/application_settings/repository.html.haml' do
end
describe 'default initial branch name' do
context 'when the feature flag is disabled' do
before do
stub_feature_flags(global_default_branch_name: false)
end
it 'does not show the setting section' do
render
expect(rendered).not_to have_css("#js-default-branch-name")
end
end
context 'when the feature flag is enabled' do
before do
stub_feature_flags(global_default_branch_name: true)
end
it 'has the setting section' do
render
......@@ -42,5 +25,4 @@ RSpec.describe 'admin/application_settings/repository.html.haml' do
expect(rendered).to have_content("Set the default name of the initial branch when creating new repositories through the user interface.")
end
end
end
end
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment