diff --git a/options/locale/locale_en-US.ini b/options/locale/locale_en-US.ini
index 460f318292..3f9cad7051 100644
--- a/options/locale/locale_en-US.ini
+++ b/options/locale/locale_en-US.ini
@@ -1103,7 +1103,8 @@ object_format_helper = Object format of the repository. Cannot be changed later.
readme = README
readme_helper = Select a README file template
readme_helper_desc = This is the place where you can write a complete description for your project.
-auto_init = Initialize repository (Adds .gitignore, License and README)
+auto_init = Initialize repository
+auto_init_description = Start the Git history with a README and optionally add License and .gitignore files.
create_repo = Create repository
default_branch = Default branch
default_branch_label = default
diff --git a/templates/repo/create.tmpl b/templates/repo/create.tmpl
index 8212033242..7ee8587435 100644
--- a/templates/repo/create.tmpl
+++ b/templates/repo/create.tmpl
@@ -29,69 +29,21 @@
+
+
+
+
+ {{$supportedReadmesLength := len .Readmes}}
+ {{/* Only offer README selection if there is an actual choice */}}
+ {{if ge $supportedReadmesLength 2}}
+
+ {{else}}
+
+ {{end}}
+
diff --git a/tests/integration/repo_generate_test.go b/tests/integration/repo_generate_test.go
index 4bd9f32119..bcee0df417 100644
--- a/tests/integration/repo_generate_test.go
+++ b/tests/integration/repo_generate_test.go
@@ -43,7 +43,7 @@ func assertRepoCreateForm(t *testing.T, htmlDoc *HTMLDoc, owner *user_model.User
// the template menu is loaded client-side, so don't assert the option exists
assert.Equal(t, templateID, htmlDoc.GetInputValueByName("repo_template"), "Unexpected repo_template selection")
- for _, name := range []string{"issue_labels", "gitignores", "license", "readme", "object_format_name"} {
+ for _, name := range []string{"issue_labels", "gitignores", "license", "object_format_name"} {
htmlDoc.AssertDropdownHasOptions(t, name)
}
}