2016-06-22 15:30:34 +05:30
- page_title "GitLab Import"
- header_title "Projects", root_path
2017-09-10 17:25:29 +05:30
2016-06-22 15:30:34 +05:30
%h3.page-title
= icon('gitlab')
Import an exported GitLab project
%hr
2017-09-10 17:25:29 +05:30
= form_tag import_gitlab_project_path, class: 'new_project', multipart: true do
.row
2018-11-08 19:23:39 +05:30
.form-group.col-12.col-sm-6
2017-09-10 17:25:29 +05:30
= label_tag :namespace_id, 'Project path', class: 'label-light'
.form-group
.input-group
- if current_user.can_select_namespace?
2018-11-08 19:23:39 +05:30
.input-group-prepend.has-tooltip{ title: root_url }
.input-group-text
= root_url
2017-09-10 17:25:29 +05:30
= select_tag :namespace_id, namespaces_options(namespace_id_from(params) || :current_user, display_path: true, extra_group: namespace_id_from(params)), class: 'select2 js-select-namespace', tabindex: 1
2016-06-22 15:30:34 +05:30
2017-09-10 17:25:29 +05:30
- else
2018-11-08 19:23:39 +05:30
.input-group-prepend.static-namespace.has-tooltip{ title: user_url(current_user.username) + '/' }
.input-group-text.border-0
#{user_url(current_user.username)}/
2017-09-10 17:25:29 +05:30
= hidden_field_tag :namespace_id, value: current_user.namespace_id
2018-11-08 19:23:39 +05:30
.form-group.col-12.col-sm-6.project-path
2017-09-10 17:25:29 +05:30
= label_tag :path, 'Project name', class: 'label-light'
= text_field_tag :path, @path, placeholder: "my-awesome-project", class: "js-path-name form-control", tabindex: 2, autofocus: true, required: true
2016-06-22 15:30:34 +05:30
2017-09-10 17:25:29 +05:30
.row
.form-group.col-md-12
To move or copy an entire GitLab project from another GitLab installation to this one, navigate to the original project's settings page, generate an export file, and upload it here.
.row
.form-group.col-sm-12
= hidden_field_tag :namespace_id, @namespace.id
= label_tag :file, 'GitLab project export', class: 'label-light'
.form-group
= file_field_tag :file, class: ''
.row
2018-11-08 19:23:39 +05:30
.form-actions.col-sm-12
2017-09-10 17:25:29 +05:30
= submit_tag 'Import project', class: 'btn btn-create'
= link_to 'Cancel', new_project_path, class: 'btn btn-cancel'