Commit 0c57782c authored by Kamil Trzciński's avatar Kamil Trzciński

Add internalization

parent 131ca31b
%h3 Group Runners - link = link_to 'Runners API', help_page_path('api/runners.md')
%h3
= _('Group Runners')
.bs-callout.bs-callout-warning .bs-callout.bs-callout-warning
GitLab Group Runners can execute code for all the projects in this group. = _('GitLab Group Runners can execute code for all the projects in this group.')
They can be managed using the #{link_to 'Runners API', help_page_path('api/runners.md')}. = _('They can be managed using the %{link}.').html_safe % { link: link }
-# Proper policies should be implemented per -# Proper policies should be implemented per
-# https://gitlab.com/gitlab-org/gitlab-ce/issues/45894 -# https://gitlab.com/gitlab-org/gitlab-ce/issues/45894
...@@ -11,9 +14,11 @@ ...@@ -11,9 +14,11 @@
locals: { registration_token: @group.runners_token, type: 'group' } locals: { registration_token: @group.runners_token, type: 'group' }
- if @group.runners.empty? - if @group.runners.empty?
%h4.underlined-title This group does not provide any group Runners yet. %h4.underlined-title
= _('This group does not provide any group Runners yet.')
- else - else
%h4.underlined-title Available group Runners : #{@group.runners.count} %h4.underlined-title
= _('Available group Runners : %{runners}.').html_safe % { runners: @group.runners.count }
%ul.bordered-list %ul.bordered-list
= render partial: 'groups/runners/runner', collection: @group.runners, as: :runner = render partial: 'groups/runners/runner', collection: @group.runners, as: :runner
...@@ -2,7 +2,8 @@ ...@@ -2,7 +2,8 @@
%hr %hr
%p.lead To start serving your jobs you can add Runners to your group %p.lead
= _('To start serving your jobs you can add Runners to your group')
.row .row
.col-sm-6 .col-sm-6
= render 'groups/runners/group_runners' = render 'groups/runners/group_runners'
...@@ -6,14 +6,14 @@ ...@@ -6,14 +6,14 @@
%small.edit-runner %small.edit-runner
= link_to edit_group_runner_path(@group, runner) do = link_to edit_group_runner_path(@group, runner) do
%i.fa.fa-edit.btn = icon('edit')
.pull-right .pull-right
- if runner.active? - if runner.active?
= link_to 'Pause', pause_group_runner_path(@group, runner), method: :post, class: 'btn btn-sm btn-danger', data: { confirm: "Are you sure?" } = link_to _('Pause'), pause_group_runner_path(@group, runner), method: :post, class: 'btn btn-sm btn-danger', data: { confirm: _("Are you sure?") }
- else - else
= link_to 'Resume', resume_group_runner_path(@group, runner), method: :post, class: 'btn btn-success btn-sm' = link_to _('Resume'), resume_group_runner_path(@group, runner), method: :post, class: 'btn btn-success btn-sm'
= link_to 'Remove Runner', group_runner_path(@group, runner), data: { confirm: "Are you sure?" }, method: :delete, class: 'btn btn-danger btn-sm' = link_to _('Remove Runner'), group_runner_path(@group, runner), data: { confirm: _("Are you sure?") }, method: :delete, class: 'btn btn-danger btn-sm'
.pull-right .pull-right
%small.light %small.light
\##{runner.id} \##{runner.id}
......
...@@ -3,25 +3,25 @@ ...@@ -3,25 +3,25 @@
- expanded = Rails.env.test? - expanded = Rails.env.test?
%section.settings.no-animate{ class: ('expanded' if expanded) } %section.settings#secret-variables.no-animate{ class: ('expanded' if expanded) }
.settings-header .settings-header
%h4 %h4
= _('Secret variables') = _('Secret variables')
= link_to icon('question-circle'), help_page_path('ci/variables/README', anchor: 'secret-variables'), target: '_blank', rel: 'noopener noreferrer' = link_to icon('question-circle'), help_page_path('ci/variables/README', anchor: 'secret-variables'), target: '_blank', rel: 'noopener noreferrer'
%button.btn.js-settings-toggle %button.btn.btn-default.js-settings-toggle{ type: "button" }
= expanded ? 'Collapse' : 'Expand' = expanded ? _('Collapse') : _('Expand')
%p.append-bottom-0 %p.append-bottom-0
= render "ci/variables/content" = render "ci/variables/content"
.settings-content .settings-content
= render 'ci/variables/index', save_endpoint: group_variables_path = render 'ci/variables/index', save_endpoint: group_variables_path
%section.settings.no-animate{ class: ('expanded' if expanded) } %section.settings#runners-settings.no-animate{ class: ('expanded' if expanded) }
.settings-header .settings-header
%h4 %h4
Runners settings = _('Runners settings')
%button.btn.js-settings-toggle %button.btn.btn-default.js-settings-toggle{ type: "button" }
= expanded ? 'Collapse' : 'Expand' = expanded ? _('Collapse') : _('Expand')
%p %p
Register and see your runners for this group. = _('Register and see your runners for this group.')
.settings-content .settings-content
= render 'groups/runners/index' = render 'groups/runners/index'
%h3 Group Runners - link = link_to 'Runners API', help_page_path('api/runners.md')
%h3
= _('Group Runners')
.bs-callout.bs-callout-warning .bs-callout.bs-callout-warning
GitLab Group Runners can execute code for all the projects in this group. = _('GitLab Group Runners can execute code for all the projects in this group.')
They can be managed using the #{link_to 'Runners API', help_page_path('api/runners.md')}. = _('They can be managed using the %{link}.').html_safe % { link: link }
- if @project.group - if @project.group
%hr %hr
- if @project.group_runners_enabled? - if @project.group_runners_enabled?
= link_to toggle_group_runners_project_runners_path(@project), class: 'btn btn-close', method: :post do = link_to toggle_group_runners_project_runners_path(@project), class: 'btn btn-close', method: :post do
Disable group Runners = _('Disable group Runners')
- else - else
= link_to toggle_group_runners_project_runners_path(@project), class: 'btn btn-success', method: :post do = link_to toggle_group_runners_project_runners_path(@project), class: 'btn btn-success', method: :post do
Enable group Runners = _('Enable group Runners')
  for this project  
= _('for this project')
- if !@project.group - if !@project.group
This project does not belong to a group and can therefore not make use of group Runners. = _('This project does not belong to a group and can therefore not make use of group Runners.')
- elsif @group_runners.empty? - elsif @group_runners.empty?
This group does not provide any group Runners yet. = _('This group does not provide any group Runners yet.')
- if can?(current_user, :admin_pipeline, @project.group) - if can?(current_user, :admin_pipeline, @project.group)
Group masters can register group runners in the - group_link = link_to 'Group CI/CD settings', group_settings_ci_cd_path(@project.group)
= link_to 'Group CI/CD settings', group_settings_ci_cd_path(@project.group) = _('Group masters can register group runners in the %{link}').html_safe % { link: group_link }
- else - else
Ask your group master to setup a group Runner. = _('Ask your group master to setup a group Runner.')
- else - else
%h4.underlined-title Available group Runners : #{@group_runners.count} %h4.underlined-title
= _('Available group Runners : %{runners}').html_safe % { runners: @group_runners.count }
%ul.bordered-list %ul.bordered-list
= render partial: 'projects/runners/runner', collection: @group_runners, as: :runner = render partial: 'projects/runners/runner', collection: @group_runners, as: :runner
...@@ -6,7 +6,7 @@ ...@@ -6,7 +6,7 @@
= link_to runner.short_sha, project_runner_path(@project, runner), class: 'commit-sha' = link_to runner.short_sha, project_runner_path(@project, runner), class: 'commit-sha'
- if runner.locked? - if runner.locked?
= icon('lock', class: 'has-tooltip', title: 'Locked to current projects') = icon('lock', class: 'has-tooltip', title: _('Locked to current projects'))
%small.edit-runner %small.edit-runner
= link_to edit_project_runner_path(@project, runner) do = link_to edit_project_runner_path(@project, runner) do
...@@ -18,18 +18,18 @@ ...@@ -18,18 +18,18 @@
.pull-right .pull-right
- if @project_runners.include?(runner) - if @project_runners.include?(runner)
- if runner.active? - if runner.active?
= link_to 'Pause', pause_project_runner_path(@project, runner), method: :post, class: 'btn btn-sm btn-danger', data: { confirm: "Are you sure?" } = link_to _('Pause'), pause_project_runner_path(@project, runner), method: :post, class: 'btn btn-sm btn-danger', data: { confirm: _("Are you sure?") }
- else - else
= link_to 'Resume', resume_project_runner_path(@project, runner), method: :post, class: 'btn btn-success btn-sm' = link_to _('Resume'), resume_project_runner_path(@project, runner), method: :post, class: 'btn btn-success btn-sm'
- if runner.belongs_to_one_project? - if runner.belongs_to_one_project?
= link_to 'Remove Runner', project_runner_path(@project, runner), data: { confirm: "Are you sure?" }, method: :delete, class: 'btn btn-danger btn-sm' = link_to _('Remove Runner'), project_runner_path(@project, runner), data: { confirm: _("Are you sure?") }, method: :delete, class: 'btn btn-danger btn-sm'
- else - else
- runner_project = @project.runner_projects.find_by(runner_id: runner) - runner_project = @project.runner_projects.find_by(runner_id: runner)
= link_to 'Disable for this project', project_runner_project_path(@project, runner_project), data: { confirm: "Are you sure?" }, method: :delete, class: 'btn btn-danger btn-sm' = link_to _('Disable for this project'), project_runner_project_path(@project, runner_project), data: { confirm: _("Are you sure?") }, method: :delete, class: 'btn btn-danger btn-sm'
- elsif !(runner.is_shared? || runner.group_type?) # We can simplify this to `runner.project_type?` when migrating #runner_type is complete - elsif !(runner.is_shared? || runner.group_type?) # We can simplify this to `runner.project_type?` when migrating #runner_type is complete
= form_for [@project.namespace.becomes(Namespace), @project, @project.runner_projects.new] do |f| = form_for [@project.namespace.becomes(Namespace), @project, @project.runner_projects.new] do |f|
= f.hidden_field :runner_id, value: runner.id = f.hidden_field :runner_id, value: runner.id
= f.submit 'Enable for this project', class: 'btn btn-sm' = f.submit _('Enable for this project'), class: 'btn btn-sm'
.pull-right .pull-right
%small.light %small.light
\##{runner.id} \##{runner.id}
......
.light.prepend-top-default .light.prepend-top-default
%p %p
A 'Runner' is a process which runs a job. = _("A 'Runner' is a process which runs a job. You can setup as many Runners as you need.")
You can setup as many Runners as you need.
%br %br
Runners can be placed on separate users, servers, and even on your local machine. = _('Runners can be placed on separate users, servers, and even on your local machine.')
%p Each Runner can be in one of the following states: %p
= _('Each Runner can be in one of the following states:')
%div %div
%ul %ul
%li %li
%span.label.label-success active %span.label.label-success active
\- Runner is active and can process any new jobs = _('- Runner is active and can process any new jobs')
%li %li
%span.label.label-danger paused %span.label.label-danger paused
\- Runner is paused and will not receive any new jobs = _('- Runner is paused and will not receive any new jobs')
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