2019-12-04 20:38:33 +05:30
|
|
|
- title = _('Authenticate with GitHub')
|
2018-03-27 19:54:05 +05:30
|
|
|
- page_title title
|
2021-09-04 01:27:46 +05:30
|
|
|
- header_title _("New project"), new_project_path
|
2021-11-18 22:05:49 +05:30
|
|
|
- add_to_breadcrumbs s_('ProjectsNew|Import project'), new_project_path(anchor: 'import_project')
|
2016-08-24 12:49:21 +05:30
|
|
|
|
2022-07-23 23:45:48 +05:30
|
|
|
%h1.page-title.gl-font-size-h-display
|
2019-12-04 20:38:33 +05:30
|
|
|
= title
|
2016-08-24 12:49:21 +05:30
|
|
|
|
2019-12-04 20:38:33 +05:30
|
|
|
%p
|
|
|
|
= import_github_authorize_message
|
2016-08-24 12:49:21 +05:30
|
|
|
|
2019-12-04 20:38:33 +05:30
|
|
|
- if github_import_configured? && !has_ci_cd_only_params?
|
2023-04-23 21:23:45 +05:30
|
|
|
= render Pajamas::ButtonComponent.new(variant: :confirm,
|
|
|
|
href: status_import_github_path(namespace_id: params[:namespace_id]),
|
|
|
|
icon: 'github') do
|
2021-01-03 14:25:43 +05:30
|
|
|
= title
|
2016-08-24 12:49:21 +05:30
|
|
|
|
|
|
|
%hr
|
|
|
|
|
2019-12-04 20:38:33 +05:30
|
|
|
- unless github_import_configured? || has_ci_cd_only_params?
|
|
|
|
.bs-callout.bs-callout-info
|
|
|
|
= import_configure_github_admin_message
|
2016-08-24 12:49:21 +05:30
|
|
|
|
2019-12-04 20:38:33 +05:30
|
|
|
= form_tag personal_access_token_import_github_path, method: :post do
|
2016-08-24 12:49:21 +05:30
|
|
|
.form-group
|
2019-12-04 20:38:33 +05:30
|
|
|
%label.label-bold= _('Personal Access Token')
|
2022-06-21 17:19:12 +05:30
|
|
|
= hidden_field_tag(:namespace_id, params[:namespace_id])
|
2021-12-11 22:18:48 +05:30
|
|
|
= text_field_tag :personal_access_token, '', class: 'form-control gl-form-input', placeholder: _('e.g. %{token}') % { token: '8d3f016698e...' }, data: { qa_selector: 'personal_access_token_field' }
|
2022-07-23 23:45:48 +05:30
|
|
|
%span.form-text.gl-text-gray-600
|
2019-12-04 20:38:33 +05:30
|
|
|
= import_github_personal_access_token_message
|
2018-03-27 19:54:05 +05:30
|
|
|
|
2019-09-04 21:01:54 +05:30
|
|
|
= render_if_exists 'import/github/ci_cd_only'
|
|
|
|
|
2022-07-23 23:45:48 +05:30
|
|
|
.form-actions.gl-display-flex.gl-justify-content-end
|
2023-04-23 21:23:45 +05:30
|
|
|
= render Pajamas::ButtonComponent.new(href: new_project_path) do
|
|
|
|
= _('Cancel')
|
|
|
|
= render Pajamas::ButtonComponent.new(variant: :confirm,
|
|
|
|
type: :submit,
|
|
|
|
button_options: { class: 'gl-ml-3', data: { qa_selector: 'authenticate_button' } }) do
|
|
|
|
= _('Authenticate')
|