Create project from template
Description
Many companies have apps that form the basis for new projects. Sometimes these are explicit template apps, sometimes they're just the last app a developer worked on. Currently, cloning a project is mainly done via the CLI and involves several steps to fix the git remotes. We should make it easy to get started with a new project, by starting from an existing one. GitLab already supports forking a project, but that doesn't quite do it. For one, I can't fork from a group into the same group; I have to fork into a different group.
Proposal
Some options:
- Extend fork to allow people to fork into the same group, while changing the name and breaking the fork relationship.
- Add a Clone button.
- Extend the new project import options to include another project on the same GitLab install.
- Create first-class project templates, kinda similar to how we do
.gitlab-ci.yml
templates, but for entire projects instead of single files. Optionally (EE only?) let administrators manage their own list of approved templates. - Leverage something like Heroku Buttons to let users find projects on their own, and then quickly clone them. (A key piece of Heroku Buttons is that there's a configuration file that specifies what a new version of the app needs, such as environment variables and add-ons, not just the code.)
- Extend template file handling to cover more and more files and groups of files. e.g. click to add a readme, click to add a Rails project, click to add a kubernetes config file.
Links
- Inspired while working on gitlab-ce#19793