summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2020-07-31 21:10:12 +0000
committerGitLab Bot <gitlab-bot@gitlab.com>2020-07-31 21:10:12 +0000
commit8bb9ee876910bf5a14e116ace9ec95791486a78a (patch)
tree7e2ad1f15f11dcbb5b45b2a581b7d720c272885d
parent04338021ada9669bcf8d6cf2d35b0debf50e8cc1 (diff)
downloadgitlab-ce-8bb9ee876910bf5a14e116ace9ec95791486a78a.tar.gz
Add latest changes from gitlab-org/gitlab@master
-rw-r--r--.haml-lint_todo.yml1
-rw-r--r--app/assets/javascripts/blob/components/blob_edit_content.vue17
-rw-r--r--app/assets/javascripts/performance_constants.js12
-rw-r--r--app/assets/javascripts/snippets/components/edit.vue4
-rw-r--r--app/assets/javascripts/snippets/components/show.vue5
-rw-r--r--app/assets/javascripts/vue_shared/components/blob_viewers/mixins.js16
-rw-r--r--app/assets/stylesheets/pages/editor.scss5
-rw-r--r--app/finders/merge_requests_finder.rb24
-rw-r--r--app/helpers/mirror_helper.rb2
-rw-r--r--app/helpers/preferences_helper.rb2
-rw-r--r--app/policies/project_policy.rb2
-rw-r--r--app/serializers/build_details_entity.rb2
-rw-r--r--app/services/merge_requests/ff_merge_service.rb1
-rw-r--r--app/views/ci/variables/_content.html.haml2
-rw-r--r--app/views/clusters/clusters/_advanced_settings.html.haml4
-rw-r--r--app/views/devise/registrations/new.html.haml2
-rw-r--r--app/views/doorkeeper/applications/_form.html.haml2
-rw-r--r--app/views/doorkeeper/authorizations/new.html.haml2
-rw-r--r--app/views/help/instance_configuration/_ssh_info.html.haml2
-rw-r--r--app/views/help/ui.html.haml524
-rw-r--r--app/views/projects/blob/_editor.html.haml3
-rw-r--r--app/views/registrations/welcome.html.haml2
-rw-r--r--app/views/shared/_delete_label_modal.html.haml2
-rw-r--r--app/views/shared/notes/_notes_with_form.html.haml2
-rw-r--r--app/views/shared/snippets/_form.html.haml3
-rw-r--r--app/views/shared/wikis/_form.html.haml2
-rw-r--r--app/views/users/calendar_activities.html.haml2
-rw-r--r--changelogs/unreleased/229468-fix-overflow-issues-with-monaco-file-editor.yml5
-rw-r--r--changelogs/unreleased/229544-populate-issue-type-for-incident-issues.yml5
-rw-r--r--changelogs/unreleased/bye-bye-ui.yml5
-rw-r--r--changelogs/unreleased/fix-review-app-link-not-shown-in-public-projects.yml5
-rw-r--r--changelogs/unreleased/kassio-remove-languages-from-ui.yml5
-rw-r--r--changelogs/unreleased/sh-track-ff-merge-pre-receive-errors.yml5
-rw-r--r--config/routes/help.rb1
-rw-r--r--db/post_migrate/20200723040950_migrate_incident_issues_to_incident_type.rb47
-rw-r--r--db/schema_migrations/202007230409501
-rw-r--r--doc/development/i18n/externalization.md4
-rw-r--r--lib/gitlab/git/pre_receive_error.rb12
-rw-r--r--lib/gitlab/gitaly_client/operation_service.rb2
-rw-r--r--lib/gitlab/i18n.rb18
-rw-r--r--lib/gitlab/i18n/html_todo.yml376
-rw-r--r--locale/gitlab.pot60
-rw-r--r--spec/controllers/help_controller_spec.rb9
-rw-r--r--spec/features/profiles/user_edit_preferences_spec.rb2
-rw-r--r--spec/features/profiles/user_visits_profile_preferences_page_spec.rb4
-rw-r--r--spec/features/security/project/internal_access_spec.rb12
-rw-r--r--spec/features/security/project/public_access_spec.rb24
-rw-r--r--spec/finders/merge_requests_finder_spec.rb68
-rw-r--r--spec/frontend/blob/components/__snapshots__/blob_edit_content_spec.js.snap10
-rw-r--r--spec/frontend/environment.js6
-rw-r--r--spec/lib/gitlab/git/pre_receive_error_spec.rb16
-rw-r--r--spec/lib/gitlab/i18n_spec.rb8
-rw-r--r--spec/migrations/migrate_incident_issues_to_incident_type_spec.rb55
-rw-r--r--spec/routing/routing_spec.rb4
-rw-r--r--spec/services/merge_requests/ff_merge_service_spec.rb9
55 files changed, 589 insertions, 836 deletions
diff --git a/.haml-lint_todo.yml b/.haml-lint_todo.yml
index df515607d36..dabf7cd9a95 100644
--- a/.haml-lint_todo.yml
+++ b/.haml-lint_todo.yml
@@ -113,7 +113,6 @@ linters:
- "app/views/help/instance_configuration.html.haml"
- "app/views/help/instance_configuration/_gitlab_ci.html.haml"
- "app/views/help/instance_configuration/_gitlab_pages.html.haml"
- - "app/views/help/ui.html.haml"
- "app/views/import/bitbucket/status.html.haml"
- "app/views/import/bitbucket_server/status.html.haml"
- "app/views/invites/show.html.haml"
diff --git a/app/assets/javascripts/blob/components/blob_edit_content.vue b/app/assets/javascripts/blob/components/blob_edit_content.vue
index 056b4ea4aa8..c53de2e7746 100644
--- a/app/assets/javascripts/blob/components/blob_edit_content.vue
+++ b/app/assets/javascripts/blob/components/blob_edit_content.vue
@@ -1,6 +1,12 @@
<script>
import { initEditorLite } from '~/blob/utils';
import { debounce } from 'lodash';
+import {
+ SNIPPET_MARK_BLOBS_CONTENT,
+ SNIPPET_MARK_EDIT_APP_START,
+ SNIPPET_MEASURE_BLOBS_CONTENT,
+ SNIPPET_MEASURE_BLOBS_CONTENT_WITHIN_APP,
+} from '~/performance_constants';
export default {
props: {
@@ -31,6 +37,13 @@ export default {
blobPath: this.fileName,
blobContent: this.value,
});
+ window.requestAnimationFrame(() => {
+ if (!performance.getEntriesByName(SNIPPET_MARK_BLOBS_CONTENT).length) {
+ performance.mark(SNIPPET_MARK_BLOBS_CONTENT);
+ performance.measure(SNIPPET_MEASURE_BLOBS_CONTENT);
+ performance.measure(SNIPPET_MEASURE_BLOBS_CONTENT_WITHIN_APP, SNIPPET_MARK_EDIT_APP_START);
+ }
+ });
},
methods: {
triggerFileChange: debounce(function debouncedFileChange() {
@@ -41,6 +54,8 @@ export default {
</script>
<template>
<div class="file-content code">
- <pre id="editor" ref="editor" data-editor-loading @keyup="triggerFileChange">{{ value }}</pre>
+ <div id="editor" ref="editor" data-editor-loading @keyup="triggerFileChange">
+ <pre class="editor-loading-content">{{ value }}</pre>
+ </div>
</div>
</template>
diff --git a/app/assets/javascripts/performance_constants.js b/app/assets/javascripts/performance_constants.js
new file mode 100644
index 00000000000..1a53b925aa4
--- /dev/null
+++ b/app/assets/javascripts/performance_constants.js
@@ -0,0 +1,12 @@
+//
+// SNIPPET namespace
+//
+
+// marks
+export const SNIPPET_MARK_VIEW_APP_START = 'snippet-view-app-start';
+export const SNIPPET_MARK_EDIT_APP_START = 'snippet-edit-app-start';
+export const SNIPPET_MARK_BLOBS_CONTENT = 'snippet-blobs-content-finished';
+
+// Measures
+export const SNIPPET_MEASURE_BLOBS_CONTENT = 'snippet-blobs-content';
+export const SNIPPET_MEASURE_BLOBS_CONTENT_WITHIN_APP = 'snippet-blobs-content-within-app';
diff --git a/app/assets/javascripts/snippets/components/edit.vue b/app/assets/javascripts/snippets/components/edit.vue
index 95d2bb0698b..896ab900fd7 100644
--- a/app/assets/javascripts/snippets/components/edit.vue
+++ b/app/assets/javascripts/snippets/components/edit.vue
@@ -21,6 +21,7 @@ import {
import SnippetBlobEdit from './snippet_blob_edit.vue';
import SnippetVisibilityEdit from './snippet_visibility_edit.vue';
import SnippetDescriptionEdit from './snippet_description_edit.vue';
+import { SNIPPET_MARK_EDIT_APP_START } from '~/performance_constants';
export default {
components: {
@@ -106,6 +107,9 @@ export default {
return `${this.isProjectSnippet ? 'project' : 'personal'}_snippet_description`;
},
},
+ beforeCreate() {
+ performance.mark(SNIPPET_MARK_EDIT_APP_START);
+ },
created() {
window.addEventListener('beforeunload', this.onBeforeUnload);
},
diff --git a/app/assets/javascripts/snippets/components/show.vue b/app/assets/javascripts/snippets/components/show.vue
index 430c701ae95..d0df0ef7b77 100644
--- a/app/assets/javascripts/snippets/components/show.vue
+++ b/app/assets/javascripts/snippets/components/show.vue
@@ -9,6 +9,8 @@ import { GlLoadingIcon } from '@gitlab/ui';
import { getSnippetMixin } from '../mixins/snippets';
import { SNIPPET_VISIBILITY_PUBLIC } from '~/snippets/constants';
+import { SNIPPET_MARK_VIEW_APP_START } from '~/performance_constants';
+
export default {
components: {
BlobEmbeddable,
@@ -27,6 +29,9 @@ export default {
return Boolean(this.snippet.sshUrlToRepo || this.snippet.httpUrlToRepo);
},
},
+ beforeCreate() {
+ performance.mark(SNIPPET_MARK_VIEW_APP_START);
+ },
};
</script>
<template>
diff --git a/app/assets/javascripts/vue_shared/components/blob_viewers/mixins.js b/app/assets/javascripts/vue_shared/components/blob_viewers/mixins.js
index 27f1a4f75d5..9e2b3097499 100644
--- a/app/assets/javascripts/vue_shared/components/blob_viewers/mixins.js
+++ b/app/assets/javascripts/vue_shared/components/blob_viewers/mixins.js
@@ -1,3 +1,10 @@
+import {
+ SNIPPET_MARK_VIEW_APP_START,
+ SNIPPET_MARK_BLOBS_CONTENT,
+ SNIPPET_MEASURE_BLOBS_CONTENT,
+ SNIPPET_MEASURE_BLOBS_CONTENT_WITHIN_APP,
+} from '~/performance_constants';
+
export default {
props: {
content: {
@@ -9,4 +16,13 @@ export default {
required: true,
},
},
+ mounted() {
+ window.requestAnimationFrame(() => {
+ if (!performance.getEntriesByName(SNIPPET_MARK_BLOBS_CONTENT).length) {
+ performance.mark(SNIPPET_MARK_BLOBS_CONTENT);
+ performance.measure(SNIPPET_MEASURE_BLOBS_CONTENT);
+ performance.measure(SNIPPET_MEASURE_BLOBS_CONTENT_WITHIN_APP, SNIPPET_MARK_VIEW_APP_START);
+ }
+ });
+ },
};
diff --git a/app/assets/stylesheets/pages/editor.scss b/app/assets/stylesheets/pages/editor.scss
index fd11d0e3a69..cc826bb6c21 100644
--- a/app/assets/stylesheets/pages/editor.scss
+++ b/app/assets/stylesheets/pages/editor.scss
@@ -16,6 +16,11 @@
padding: 0;
position: relative;
width: 100%;
+
+ .editor-loading-content {
+ height: 100%;
+ border: 0;
+ }
}
.ace_gutter-cell {
diff --git a/app/finders/merge_requests_finder.rb b/app/finders/merge_requests_finder.rb
index d5e6c4783c1..ceb015ad41f 100644
--- a/app/finders/merge_requests_finder.rb
+++ b/app/finders/merge_requests_finder.rb
@@ -31,7 +31,7 @@
#
class MergeRequestsFinder < IssuableFinder
def self.scalar_params
- @scalar_params ||= super + [:wip, :target_branch]
+ @scalar_params ||= super + [:wip, :draft, :target_branch]
end
def klass
@@ -42,7 +42,7 @@ class MergeRequestsFinder < IssuableFinder
items = by_commit(super)
items = by_deployment(items)
items = by_source_branch(items)
- items = by_wip(items)
+ items = by_draft(items)
items = by_target_branch(items)
by_source_project_id(items)
end
@@ -88,20 +88,32 @@ class MergeRequestsFinder < IssuableFinder
items.where(source_project_id: source_project_id)
end
- def by_wip(items)
- if params[:wip] == 'yes'
+ def by_draft(items)
+ draft_param = params[:draft] || params[:wip]
+
+ if draft_param == 'yes'
items.where(wip_match(items.arel_table))
- elsif params[:wip] == 'no'
+ elsif draft_param == 'no'
items.where.not(wip_match(items.arel_table))
else
items
end
end
+ # WIP is deprecated in favor of Draft. Currently both options are supported
def wip_match(table)
- table[:title].matches('WIP:%')
+ items =
+ table[:title].matches('WIP:%')
.or(table[:title].matches('WIP %'))
.or(table[:title].matches('[WIP]%'))
+
+ return items unless Feature.enabled?(:merge_request_draft_filter)
+
+ items
+ .or(table[:title].matches('Draft - %'))
+ .or(table[:title].matches('Draft:%'))
+ .or(table[:title].matches('[Draft]%'))
+ .or(table[:title].matches('(Draft)%'))
end
def by_deployment(items)
diff --git a/app/helpers/mirror_helper.rb b/app/helpers/mirror_helper.rb
index 6f6cb91e696..50fc5e521fc 100644
--- a/app/helpers/mirror_helper.rb
+++ b/app/helpers/mirror_helper.rb
@@ -9,7 +9,7 @@ module MirrorHelper
end
def mirror_lfs_sync_message
- _('The Git LFS objects will <strong>not</strong> be synced.').html_safe
+ html_escape(_('The Git LFS objects will %{strong_open}not%{strong_close} be synced.')) % { strong_open: '<strong>'.html_safe, strong_close: '</strong>'.html_safe }
end
end
diff --git a/app/helpers/preferences_helper.rb b/app/helpers/preferences_helper.rb
index 271359fcfd1..5a917a02d51 100644
--- a/app/helpers/preferences_helper.rb
+++ b/app/helpers/preferences_helper.rb
@@ -71,7 +71,7 @@ module PreferencesHelper
def language_choices
options_for_select(
- Gitlab::I18n::AVAILABLE_LANGUAGES.map(&:reverse).sort,
+ Gitlab::I18n.selectable_locales.map(&:reverse).sort,
current_user.preferred_language
)
end
diff --git a/app/policies/project_policy.rb b/app/policies/project_policy.rb
index 38507a5ea78..41274fe9db4 100644
--- a/app/policies/project_policy.rb
+++ b/app/policies/project_policy.rb
@@ -478,6 +478,8 @@ class ProjectPolicy < BasePolicy
enable :read_note
enable :read_pipeline
enable :read_pipeline_schedule
+ enable :read_environment
+ enable :read_deployment
enable :read_commit_status
enable :read_container_image
enable :download_code
diff --git a/app/serializers/build_details_entity.rb b/app/serializers/build_details_entity.rb
index df1bdc2b7a4..6036a9db288 100644
--- a/app/serializers/build_details_entity.rb
+++ b/app/serializers/build_details_entity.rb
@@ -147,7 +147,7 @@ class BuildDetailsEntity < JobEntity
end
def help_message(docs_url)
- _("Please refer to <a href=\"%{docs_url}\">%{docs_url}</a>") % { docs_url: docs_url }
+ html_escape(_("Please refer to %{docs_url}")) % { docs_url: "<a href=\"#{docs_url}\">#{html_escape(docs_url)}</a>".html_safe }
end
end
diff --git a/app/services/merge_requests/ff_merge_service.rb b/app/services/merge_requests/ff_merge_service.rb
index b3896d61a78..79011094e88 100644
--- a/app/services/merge_requests/ff_merge_service.rb
+++ b/app/services/merge_requests/ff_merge_service.rb
@@ -22,6 +22,7 @@ module MergeRequests
ff_merge
rescue Gitlab::Git::PreReceiveError => e
+ Gitlab::ErrorTracking.track_exception(e, pre_receive_message: e.raw_message, merge_request_id: merge_request&.id)
raise MergeError, e.message
rescue StandardError => e
raise MergeError, "Something went wrong during merge: #{e.message}"
diff --git a/app/views/ci/variables/_content.html.haml b/app/views/ci/variables/_content.html.haml
index 144d13565b2..60106e8c530 100644
--- a/app/views/ci/variables/_content.html.haml
+++ b/app/views/ci/variables/_content.html.haml
@@ -1,3 +1,3 @@
= _('Environment variables are applied to environments via the runner. They can be protected by only exposing them to protected branches or tags. Additionally, they can be masked so they are hidden in job logs, though they must match certain regexp requirements to do so. You can use environment variables for passwords, secret keys, or whatever you want.')
-= _('You may also add variables that are made available to the running application by prepending the variable key with <code>K8S_SECRET_</code>.').html_safe
+= html_escape(_('You may also add variables that are made available to the running application by prepending the variable key with %{k8s_secret}.')) % { k8s_secret: tag.code('K8S_SECRET_') }
= link_to _('More information'), help_page_path('ci/variables/README', anchor: 'custom-environment-variables')
diff --git a/app/views/clusters/clusters/_advanced_settings.html.haml b/app/views/clusters/clusters/_advanced_settings.html.haml
index 5e88bb75a7a..117bdbc06a1 100644
--- a/app/views/clusters/clusters/_advanced_settings.html.haml
+++ b/app/views/clusters/clusters/_advanced_settings.html.haml
@@ -11,7 +11,7 @@
= @cluster.provider_label
%p
- provider_link = link_to(@cluster.provider_label, @cluster.provider_management_url, target: '_blank', rel: 'noopener noreferrer')
- = s_('ClusterIntegration|Manage your Kubernetes cluster by visiting %{provider_link}').html_safe % { provider_link: provider_link }
+ = html_escape(s_('ClusterIntegration|Manage your Kubernetes cluster by visiting %{provider_link}')) % { provider_link: provider_link }
.sub-section.form-group
= form_for @cluster, url: clusterable.cluster_path(@cluster), as: :cluster, html: { class: 'cluster_management_form' } do |field|
@@ -22,7 +22,7 @@
= project_select_tag('cluster[management_project_id]', class: 'hidden-filter-value', toggle_class: 'js-project-search js-project-filter js-filter-submit', dropdown_class: 'dropdown-menu-selectable dropdown-menu-project js-filter-submit',
placeholder: _('Select project'), idAttribute: 'id', data: { order_by: 'last_activity_at', idattribute: 'id', simple_filter: true, allow_clear: true, include_groups: false, include_projects_in_subgroups: true, group_id: group_id, user_id: user_id }, value: @cluster.management_project_id)
.text-muted
- = s_('ClusterIntegration|A cluster management project can be used to run deployment jobs with Kubernetes <code>cluster-admin</code> privileges.').html_safe
+ = html_escape(s_('ClusterIntegration|A cluster management project can be used to run deployment jobs with Kubernetes %{code_open}cluster-admin%{code_close} privileges.')) % { code_open: '<code>'.html_safe, code_close: '</code>'.html_safe }
= link_to _('More information'), help_page_path('user/clusters/management_project.md'), target: '_blank'
.gl-display-flex.gl-justify-content-end
= field.submit _('Save changes'), class: 'btn btn-success'
diff --git a/app/views/devise/registrations/new.html.haml b/app/views/devise/registrations/new.html.haml
index fb00e1b4384..afdf3c38567 100644
--- a/app/views/devise/registrations/new.html.haml
+++ b/app/views/devise/registrations/new.html.haml
@@ -3,7 +3,7 @@
.row
.col-lg-7
%h1.mb-3.font-weight-bold.text-6.mt-0
- = _("Speed up your DevOps<br>with GitLab").html_safe
+ = html_escape(_("Speed up your DevOps%{br_tag}with GitLab")) % { br_tag: '<br/>'.html_safe }
%p.text-3
= _("GitLab is a single application for the entire software development lifecycle. From project planning and source code management to CI/CD, monitoring, and security.")
.col-lg-5.order-12
diff --git a/app/views/doorkeeper/applications/_form.html.haml b/app/views/doorkeeper/applications/_form.html.haml
index d74cba984e8..7fbaa35d1d5 100644
--- a/app/views/doorkeeper/applications/_form.html.haml
+++ b/app/views/doorkeeper/applications/_form.html.haml
@@ -13,7 +13,7 @@
= _('Use one line per URI')
- if Doorkeeper.configuration.native_redirect_uri
%span.form-text.text-muted
- = _('Use <code>%{native_redirect_uri}</code> for local tests').html_safe % { native_redirect_uri: Doorkeeper.configuration.native_redirect_uri }
+ = html_escape(_('Use %{native_redirect_uri} for local tests')) % { native_redirect_uri: tag.code(Doorkeeper.configuration.native_redirect_uri) }
.form-group.form-check
= f.check_box :confidential, class: 'form-check-input'
diff --git a/app/views/doorkeeper/authorizations/new.html.haml b/app/views/doorkeeper/authorizations/new.html.haml
index 70abc1a267a..62e66486a3e 100644
--- a/app/views/doorkeeper/authorizations/new.html.haml
+++ b/app/views/doorkeeper/authorizations/new.html.haml
@@ -11,7 +11,7 @@
.text-warning
%p
= icon("exclamation-triangle fw")
- = _('You are an admin, which means granting access to <strong>%{client_name}</strong> will allow them to interact with GitLab as an admin as well. Proceed with caution.').html_safe % { client_name: @pre_auth.client.name }
+ = html_escape(_('You are an admin, which means granting access to %{client_name} will allow them to interact with GitLab as an admin as well. Proceed with caution.')) % { client_name: tag.strong(@pre_auth.client.name) }
%p
- link_to_client = link_to(@pre_auth.client.name, @pre_auth.redirect_uri, target: '_blank', rel: 'noopener noreferrer')
= _("An application called %{link_to_client} is requesting access to your GitLab account.").html_safe % { link_to_client: link_to_client }
diff --git a/app/views/help/instance_configuration/_ssh_info.html.haml b/app/views/help/instance_configuration/_ssh_info.html.haml
index a7ee37b2784..2c6ada4d3f2 100644
--- a/app/views/help/instance_configuration/_ssh_info.html.haml
+++ b/app/views/help/instance_configuration/_ssh_info.html.haml
@@ -9,7 +9,7 @@
- if ssh_info.blank?
%p
- = _('SSH host keys are not available on this system. Please use <code>ssh-keyscan</code> command or contact your GitLab administrator for more information.').html_safe
+ = html_escape(_('SSH host keys are not available on this system. Please use %{ssh_keyscan} command or contact your GitLab administrator for more information.')) % { ssh_keyscan: tag.code('ssh-keyscan') }
- else
%p
= _('Below are the fingerprints for the current instance SSH host keys.')
diff --git a/app/views/help/ui.html.haml b/app/views/help/ui.html.haml
deleted file mode 100644
index b34ca5abb65..00000000000
--- a/app/views/help/ui.html.haml
+++ /dev/null
@@ -1,524 +0,0 @@
-- page_title _("UI Development Kit"), _("Help")
-- lorem = "Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed fermentum nisi sapien, non consequat lectus aliquam ultrices. Suspendisse sodales est euismod nunc condimentum, a consectetur diam ornare."
-- link_classes = "flex-grow-1 mx-1 "
-
-.gitlab-ui-dev-kit
- %h1 GitLab UI development kit
- %p.light
- Use page inspector in your browser to check element classes and structure
- of examples below.
- %hr
- %ul
- %li
- = link_to 'Blocks', '#blocks'
- %li
- = link_to 'Lists', '#lists'
- %li
- = link_to 'Tables', '#tables'
- %li
- = link_to 'Nav', '#nav'
- %li
- = link_to 'Buttons', '#buttons'
- %li
- = link_to 'Dropdowns', '#dropdowns'
- %li
- = link_to 'Panels', '#panels'
- %li
- = link_to 'Alerts', '#alerts'
- %li
- = link_to 'Forms', '#forms'
- %li
- = link_to 'Files', '#file'
- %li
- = link_to 'Markdown', '#markdown'
-
- %h2#blocks Blocks
-
- .lead
- Content block separated with botton border
- %code .content-block
-
- .example
- .content-block
- %h4 Normal block inside content
- = lorem
-
- .content-block
- %h4 Second block
- = lorem
-
- .lead
- Gray content block with side padding using
- %code .row-content-block
-
- .example
- .row-content-block
- %h4 Normal block inside content
- = lorem
-
- .row-content-block.second-block
- %h4 Second block
- = lorem
-
-
- .lead
- Cover block for profile page with avatar, name and description
- %code .cover-block
- .example
- .cover-block.user-cover-block
- = render layout: 'users/cover_controls' do
- = link_to '#', class: link_classes + 'btn btn-default' do
- = sprite_icon('pencil')
- = link_to '#', class: link_classes + 'btn btn-svg btn-default' do
- = sprite_icon('rss', css_class: 'qa-rss-icon', size: 16)
- .avatar-holder
- = image_tag avatar_icon_for_email('admin@example.com', 90), class: "avatar s90", alt: ''
- .cover-title
- John Smith
-
- .cover-desc.cgray
- = lorem
-
- %h2#lists Lists
-
- .lead
- Simple list using
- %code .content-list
-
- .example
- %ul.content-list
- %li
- One item
- %li
- One item
- %li
- One item
-
- .lead
- List with avatar, title and description using
- %code .content-list
-
- .example
- %ul.content-list
- %li
- = image_tag 'no_avatar.png', class: 'avatar s40'
- .title Title
- .description Description
- %li
- = image_tag 'no_avatar.png', class: 'avatar s40'
- .title Title
- .description Description
- %li
- = image_tag 'no_avatar.png', class: 'avatar s40'
- .title Title
- .description Description
-
- .lead
- List with hover effect
- %code .hover-list
- .example
- %ul.hover-list
- %li
- One item
- %li
- One item
- %li
- One item
-
- .lead
- List inside panel
- .example
- .card
- .card-header Your list
- %ul.content-list
- %li
- One item
- %li
- One item
- %li
- One item
-
- %h2#tables Tables
-
- .example
- %table.table
- %thead
- %tr
- %th #
- %th First Name
- %th Last Name
- %th Username
- %tbody
- %tr
- %td 1
- %td Mark
- %td Otto
- %td @mdo
- %tr
- %td 2
- %td Jacob
- %td Thornton
- %td @fat
- %tr
- %td 3
- %td Larry
- %td the Bird
- %td @twitter
-
- %h2#navs Navigation
-
- .lead
- Holder for top page navigation. Includes navigation, search field, sorting and button
- %code .top-area
-
- .example
- .top-area
- %ul.nav-links.nav.nav-tabs
- %li.active
- %a Open
- %li
- %a Closed
- .nav-controls
- = text_field_tag 'sample', nil, class: 'form-control'
- .dropdown
- %button.dropdown-menu-toggle{ type: 'button', 'data-toggle' => 'dropdown' }
- %span Sort by name
- = icon('chevron-down')
- %ul.dropdown-menu
- %li
- = link_to 'Sort by date', '#'
-
- = link_to 'New issue', '#', class: 'btn btn-success btn-inverted'
-
- .lead
- Only nav links without button and search
- %code .nav-links
- .example
- %ul.nav-links
- %li.active
- %a Open
- %li
- %a Closed
-
-
- %h2#buttons Buttons
-
- .example
- %button.btn.btn-default{ :type => "button" } Secondary
- %button.btn.btn-primary{ :type => "button" } Primary
- %button.btn.btn-success{ :type => "button" } Success
- %button.btn.btn-info{ :type => "button" } Info
- %button.btn.btn-warning{ :type => "button" } Warning
- %button.btn.btn-danger{ :type => "button" } Danger
- %button.btn.btn-link{ :type => "button" } Link
-
- %h2#dropdowns Dropdowns
-
- .example
- .clearfix
- .dropdown.inline.float-left
- %button.dropdown-menu-toggle{ type: 'button', data: { toggle: 'dropdown' } }
- Dropdown
- = icon('chevron-down')
- %ul.dropdown-menu
- %li
- %a{ href: "#" }
- Dropdown option
- .dropdown.inline.float-right
- %button.dropdown-menu-toggle{ type: 'button', data: { toggle: 'dropdown' } }
- Dropdown
- = icon('chevron-down')
- %ul.dropdown-menu.dropdown-menu-right
- %li
- %a{ href: "#" }
- Dropdown option
- .example
- %div
- .dropdown.inline
- %button.dropdown-menu-toggle{ type: 'button', data: { toggle: 'dropdown' } }
- Dropdown
- = icon('chevron-down')
- %ul.dropdown-menu.dropdown-menu-selectable
- %li
- %a.is-active{ href: "#" }
- Dropdown option
- .example
- %div
- .dropdown.inline
- %button.dropdown-menu-toggle{ type: 'button', data: { toggle: 'dropdown' } }
- Dropdown
- = icon('chevron-down')
- .dropdown-menu.dropdown-select.dropdown-menu-selectable
- .dropdown-title
- %span Dropdown title
- %button.dropdown-title-button.dropdown-menu-close{ aria: { label: "Close" } }
- = icon('times')
- .dropdown-input
- %input.dropdown-input-field{ type: "search", placeholder: "Filter results" }
- = icon('search')
- .dropdown-content
- %ul
- %li
- %a.is-active{ href: "#" }
- Dropdown option
- %li
- %a{ href: "#" }
- Dropdown option
- %li.divider
- %li
- %a{ href: "#" }
- Dropdown option
- %li
- %a{ href: "#" }
- Dropdown option
- %li
- %a{ href: "#" }
- Dropdown option
- %li
- %a{ href: "#" }
- Dropdown option
- %li
- %a{ href: "#" }
- Dropdown option
- .dropdown-footer
- %strong Tip:
- If an author is not a member of this project, you can still filter by their name while using the search field.
- .dropdown.inline
- %button.dropdown-menu-toggle{ type: 'button', data: { toggle: 'dropdown' } }
- Dropdown loading
- = icon('chevron-down')
- .dropdown-menu.dropdown-select.dropdown-menu-selectable.is-loading
- .dropdown-title
- %span Dropdown title
- %button.dropdown-title-button.dropdown-menu-close{ aria: { label: "Close" } }
- = icon('times')
- .dropdown-input
- %input.dropdown-input-field{ type: "search", placeholder: "Filter results" }
- = icon('search')
- .dropdown-content
- %ul
- %li
- %a.is-active{ href: "#" }
- Dropdown option
- %li
- %a{ href: "#" }
- Dropdown option
- %li.divider
- %li
- %a{ href: "#" }
- Dropdown option
- %li
- %a{ href: "#" }
- Dropdown option
- %li
- %a{ href: "#" }
- Dropdown option
- %li
- %a{ href: "#" }
- Dropdown option
- %li
- %a{ href: "#" }
- Dropdown option
- .dropdown-footer
- %strong Tip:
- If an author is not a member of this project, you can still filter by their name while using the search field.
- .dropdown-loading.text-center
- .spinner.spinner-md.mt-8
-
- .example
- %div
- .dropdown.inline
- %button.dropdown-menu-toggle{ type: 'button', data: {toggle: 'dropdown' } }
- Dropdown user
- = icon('chevron-down')
- .dropdown-menu.dropdown-select.dropdown-menu-selectable.dropdown-menu-user
- .dropdown-title
- %span Dropdown title
- %button.dropdown-title-button.dropdown-menu-close{ aria: { label: "Close" } }
- = icon('times')
- .dropdown-input
- %input.dropdown-input-field{ type: "search", placeholder: "Filter results" }
- = icon('search')
- .dropdown-content
- %ul
- %li
- %a.dropdown-menu-user-link.is-active{ href: "#" }
- = link_to_member_avatar(@user, size: 30)
- %strong.dropdown-menu-user-full-name
- = @user.name
- .dropdown-menu-user-username
- = @user.to_reference
-
- .example
- %div
- .dropdown.inline
- %button.dropdown-menu-toggle{ type: 'button', data: { toggle: 'dropdown' } }
- Dropdown page 2
- = icon('chevron-down')
- .dropdown-menu.dropdown-select.dropdown-menu-selectable.dropdown-menu-user.dropdown-menu-paging.is-page-two
- .dropdown-page-one
- .dropdown-title
- %button.dropdown-title-button.dropdown-menu-back{ aria: { label: "Go back" } }
- = icon('arrow-left')
- %span Dropdown title
- %button.dropdown-title-button.dropdown-menu-close{ aria: { label: "Close" } }
- = icon('times')
- .dropdown-input
- %input.dropdown-input-field{ type: "search", placeholder: "Filter results" }
- = icon('search')
- .dropdown-content
- %ul
- %li
- %a.dropdown-menu-user-link.is-active{ href: "#" }
- = link_to_member_avatar(@user, size: 30)
- %strong.dropdown-menu-user-full-name
- = @user.name
- .dropdown-menu-user-username
- = @user.to_reference
- .dropdown-page-two
- .dropdown-title
- %button.dropdown-title-button.dropdown-menu-back{ aria: { label: "Go back" } }
- = icon('arrow-left')
- %span Create label
- %button.dropdown-title-button.dropdown-menu-close{ aria: { label: "Close" } }
- = icon('times')
- .dropdown-input
- %input.dropdown-input-field{ type: "search", placeholder: "Name new label" }
- .dropdown-content
- %button.btn.btn-primary
- Create
-
- .example
- %div
- .dropdown.inline
- %button#js-project-dropdown.dropdown-menu-toggle{ type: 'button', data: { toggle: 'dropdown' } }
- Projects
- = icon('chevron-down')
- .dropdown-menu.dropdown-select.dropdown-menu-selectable
- .dropdown-title
- %span Go to project
- %button.dropdown-title-button.dropdown-menu-close{ aria: { label: "Close" } }
- = icon('times')
- .dropdown-input
- %input.dropdown-input-field{ type: "search", placeholder: "Filter results" }
- = icon('search')
- .dropdown-content
- .dropdown-loading.text-center
- .spinner.spinner-md.mt-8
-
- .example
- %div
- = dropdown_tag("Projects", options: { title: "Go to project", filter: true, placeholder: "Filter projects" })
-
- %h2#panels Panels
-
- .row
- .col-md-6
- .card.bg-success
- .card-header Success
- .card-body
- = lorem
- .card.bg-primary
- .card-header Primary
- .card-body
- = lorem
- .card.bg-info
- .card-header Info
- .card-body
- = lorem
- .col-md-6
- .card.bg-warning
- .card-header Warning
- .card-body
- = lorem
- .card.bg-danger
- .card-header Danger
- .card-body
- = lorem
-
- %h2#alerts Alerts
-
- .row
- .col-md-6
- .alert.alert-success
- = lorem
- .alert.alert-info
- = lorem
- .col-md-6
- .alert.alert-warning
- = lorem
- .alert.alert-danger
- = lorem
-
- %h2#forms Forms
-
- .lead
- Horizontal form when label rendered inline with input
- %code form.horizontal-form
-
- .example
- %form
- .form-group.row
- %label.col-sm-2.col-form-label{ :for => "inputEmail3" } Email
- .col-sm-10
- %input#inputEmail3.form-control{ :placeholder => "Email", :type => "email" }/
- .form-group.row
- %label.col-sm-2.col-form-label{ :for => "inputPassword3" } Password
- .col-sm-10
- %input#inputPassword3.form-control{ :placeholder => "Password", :type => "password" }/
- .form-group.row
- .offset-sm-2.col-sm-10
- .form-check
- %input.form-check-input{ :type => "checkbox" }/
- %label.form-check-label
- Remember me
- .form-group.row
- .offset-sm-2.col-sm-10
- %button.btn.btn-default{ :type => "submit" } Sign in
-
- .lead
- Form when label rendered above input
- %code form
-
- .example
- %form
- .form-group
- %label{ :for => "exampleInputEmail1" } Email address
- %input#exampleInputEmail1.form-control{ :placeholder => "Enter email", :type => "email" }/
- .form-group
- %label{ :for => "exampleInputPassword1" } Password
- %input#exampleInputPassword1.form-control{ :placeholder => "Password", :type => "password" }/
- .form-check
- %input.form-check-input{ :type => "checkbox" }/
- %label.form-check-label
- Remember me
- %button.btn.btn-default{ :type => "submit" } Sign in
-
- %h2#file File
- %h4
- %code .file-holder
-
- - blob = Snippet.new(content: "Wow\nSuch\nFile").blob
- .example
- .file-holder
- .js-file-title.file-title
- Awesome file
- .file-actions
- .btn-group
- %a.btn Edit
- %a.btn.btn-danger Remove
- = render 'shared/file_highlight', blob: blob
-
- %h2#markdown Markdown
- %h4
- %code .md
-
- Markdown rendering has a bit different css and presented in next UI elements:
-
- %ul
- %li comment
- %li issue, merge request description
- %li wiki page
- %li help page
-
- You can check how markdown rendered at #{link_to 'Markdown help page', help_page_path("user/markdown")}.
diff --git a/app/views/projects/blob/_editor.html.haml b/app/views/projects/blob/_editor.html.haml
index 0924e9a35f5..787dc3b030f 100644
--- a/app/views/projects/blob/_editor.html.haml
+++ b/app/views/projects/blob/_editor.html.haml
@@ -40,7 +40,8 @@
= select_tag :encoding, options_for_select([ "base64", "text" ], "text"), class: 'select2', tabindex: '-1'
.file-editor.code
- %pre.js-edit-mode-pane.qa-editor#editor{ data: { 'editor-loading': true } }= params[:content] || local_assigns[:blob_data]
+ .js-edit-mode-pane.qa-editor#editor{ data: { 'editor-loading': true } }<
+ %pre.editor-loading-content= params[:content] || local_assigns[:blob_data]
- if local_assigns[:path]
.js-edit-mode-pane#preview.hide
.center
diff --git a/app/views/registrations/welcome.html.haml b/app/views/registrations/welcome.html.haml
index bc8d7ed10ef..ef3e0b1b4c0 100644
--- a/app/views/registrations/welcome.html.haml
+++ b/app/views/registrations/welcome.html.haml
@@ -1,6 +1,6 @@
- content_for(:page_title, _('Welcome to GitLab %{name}!') % { name: current_user.name })
.text-center.mb-3
- = _('In order to tailor your experience with GitLab we<br>would like to know a bit more about you.').html_safe
+ = html_escape(_('In order to tailor your experience with GitLab we%{br_tag}would like to know a bit more about you.')) % { br_tag: '<br/>'.html_safe }
.signup-box.p-3.mb-2
.signup-body
= form_for(current_user, url: users_sign_up_update_registration_path, html: { class: 'new_new_user gl-show-field-errors', 'aria-live' => 'assertive' }) do |f|
diff --git a/app/views/shared/_delete_label_modal.html.haml b/app/views/shared/_delete_label_modal.html.haml
index 25c841d2344..ffc34ff34c3 100644
--- a/app/views/shared/_delete_label_modal.html.haml
+++ b/app/views/shared/_delete_label_modal.html.haml
@@ -8,7 +8,7 @@
.modal-body
%p
- = _('<strong>%{label_name}</strong> <span>will be permanently deleted from %{subject_name}. This cannot be undone.</span>').html_safe % { label_name: label.name, subject_name: label.subject_name }
+ = html_escape(_('%{label_name} %{span_open}will be permanently deleted from %{subject_name}. This cannot be undone.%{span_close}')) % { label_name: tag.strong(label.name), subject_name: label.subject_name, span_open: '<span>'.html_safe, span_close: '</span>'.html_safe }
.modal-footer
%a{ href: '#', data: { dismiss: 'modal' }, class: 'btn btn-default' }= _('Cancel')
diff --git a/app/views/shared/notes/_notes_with_form.html.haml b/app/views/shared/notes/_notes_with_form.html.haml
index fa103ad447a..f712b139c57 100644
--- a/app/views/shared/notes/_notes_with_form.html.haml
+++ b/app/views/shared/notes/_notes_with_form.html.haml
@@ -27,6 +27,6 @@
%span.issuable-note-warning
= sprite_icon('lock', size: 16, css_class: 'icon')
%span
- = _("This %{issuable} is locked. Only <strong>project members</strong> can comment.").html_safe % { issuable: issuable.class.to_s.titleize.downcase }
+ = html_escape(_("This %{issuable} is locked. Only %{strong_open}project members%{strong_close} can comment.")) % { issuable: issuable.class.to_s.titleize.downcase, strong_open: '<strong>'.html_safe, strong_close: '</strong>'.html_safe }
-# haml-lint:disable InlineJavaScript
%script.js-notes-data{ type: "application/json" }= initial_notes_data(autocomplete).to_json.html_safe
diff --git a/app/views/shared/snippets/_form.html.haml b/app/views/shared/snippets/_form.html.haml
index 7f307f33b51..81277b50d13 100644
--- a/app/views/shared/snippets/_form.html.haml
+++ b/app/views/shared/snippets/_form.html.haml
@@ -29,7 +29,8 @@
.js-file-title.file-title-flex-parent
= f.text_field :file_name, placeholder: s_("Snippets|Give your file a name to add code highlighting, e.g. example.rb for Ruby"), class: 'form-control js-snippet-file-name', data: { qa_selector: 'file_name_field' }
.file-content.code
- %pre#editor{ data: { 'editor-loading': true } }= @snippet.content
+ #editor{ data: { 'editor-loading': true } }<
+ %pre.editor-loading-content= @snippet.content
= f.hidden_field :content, class: 'snippet-file-content'
.form-group
diff --git a/app/views/shared/wikis/_form.html.haml b/app/views/shared/wikis/_form.html.haml
index 92b9207aaa4..4d64521f9b0 100644
--- a/app/views/shared/wikis/_form.html.haml
+++ b/app/views/shared/wikis/_form.html.haml
@@ -59,7 +59,7 @@
- link_example = '[[page-slug]]'
- else
- link_example = '[Link Title](page-slug)'
- = (s_('WikiMarkdownTip|To link to a (new) page, simply type <code class="js-markup-link-example">%{link_example}</code>') % { link_example: link_example }).html_safe
+ = html_escape(s_('WikiMarkdownTip|To link to a (new) page, simply type %{link_example}')) % { link_example: tag.code(link_example, class: 'js-markup-link-example') }
= succeed '.' do
- markdown_link = link_to s_("WikiMarkdownDocs|documentation"), help_page_path('user/markdown', anchor: 'wiki-specific-markdown')
= (s_("WikiMarkdownDocs|More examples are in the %{docs_link}") % { docs_link: markdown_link }).html_safe
diff --git a/app/views/users/calendar_activities.html.haml b/app/views/users/calendar_activities.html.haml
index a0dc7580757..111f7e169b9 100644
--- a/app/views/users/calendar_activities.html.haml
+++ b/app/views/users/calendar_activities.html.haml
@@ -1,5 +1,5 @@
%h4.prepend-top-20
- = _("Contributions for <strong>%{calendar_date}</strong>").html_safe % { calendar_date: @calendar_date.to_s(:medium) }
+ = html_escape(_("Contributions for %{calendar_date}")) % { calendar_date: tag.strong(@calendar_date.to_s(:medium)) }
- if @events.any?
%ul.bordered-list
diff --git a/changelogs/unreleased/229468-fix-overflow-issues-with-monaco-file-editor.yml b/changelogs/unreleased/229468-fix-overflow-issues-with-monaco-file-editor.yml
new file mode 100644
index 00000000000..2268aa66a10
--- /dev/null
+++ b/changelogs/unreleased/229468-fix-overflow-issues-with-monaco-file-editor.yml
@@ -0,0 +1,5 @@
+---
+title: Fix overflow issues with monaco file editor
+merge_request: 37984
+author:
+type: fixed
diff --git a/changelogs/unreleased/229544-populate-issue-type-for-incident-issues.yml b/changelogs/unreleased/229544-populate-issue-type-for-incident-issues.yml
new file mode 100644
index 00000000000..3552e15f0be
--- /dev/null
+++ b/changelogs/unreleased/229544-populate-issue-type-for-incident-issues.yml
@@ -0,0 +1,5 @@
+---
+title: Migrate all 'incident' labelled issues to have issue type 'incident'
+merge_request: 37668
+author:
+type: added
diff --git a/changelogs/unreleased/bye-bye-ui.yml b/changelogs/unreleased/bye-bye-ui.yml
new file mode 100644
index 00000000000..2b7cc09f17e
--- /dev/null
+++ b/changelogs/unreleased/bye-bye-ui.yml
@@ -0,0 +1,5 @@
+---
+title: Removes the old UI page
+merge_request: 38277
+author:
+type: other
diff --git a/changelogs/unreleased/fix-review-app-link-not-shown-in-public-projects.yml b/changelogs/unreleased/fix-review-app-link-not-shown-in-public-projects.yml
new file mode 100644
index 00000000000..c5b2f03e877
--- /dev/null
+++ b/changelogs/unreleased/fix-review-app-link-not-shown-in-public-projects.yml
@@ -0,0 +1,5 @@
+---
+title: Fix review app links are not shown in MR widgets in public projects
+merge_request: 37923
+author:
+type: fixed
diff --git a/changelogs/unreleased/kassio-remove-languages-from-ui.yml b/changelogs/unreleased/kassio-remove-languages-from-ui.yml
new file mode 100644
index 00000000000..11eb73a94bc
--- /dev/null
+++ b/changelogs/unreleased/kassio-remove-languages-from-ui.yml
@@ -0,0 +1,5 @@
+---
+title: Hide languages with few translations
+merge_request: 38312
+author:
+type: changed
diff --git a/changelogs/unreleased/sh-track-ff-merge-pre-receive-errors.yml b/changelogs/unreleased/sh-track-ff-merge-pre-receive-errors.yml
new file mode 100644
index 00000000000..eefbef5b936
--- /dev/null
+++ b/changelogs/unreleased/sh-track-ff-merge-pre-receive-errors.yml
@@ -0,0 +1,5 @@
+---
+title: Log raw pre-receive message in fast-forward merge
+merge_request: 38354
+author:
+type: other
diff --git a/config/routes/help.rb b/config/routes/help.rb
index 2ea8bfd7aed..446310ba314 100644
--- a/config/routes/help.rb
+++ b/config/routes/help.rb
@@ -1,5 +1,4 @@
get 'help' => 'help#index'
get 'help/shortcuts' => 'help#shortcuts'
-get 'help/ui' => 'help#ui'
get 'help/instance_configuration' => 'help#instance_configuration'
get 'help/*path' => 'help#show', as: :help_page
diff --git a/db/post_migrate/20200723040950_migrate_incident_issues_to_incident_type.rb b/db/post_migrate/20200723040950_migrate_incident_issues_to_incident_type.rb
new file mode 100644
index 00000000000..0f562630381
--- /dev/null
+++ b/db/post_migrate/20200723040950_migrate_incident_issues_to_incident_type.rb
@@ -0,0 +1,47 @@
+# frozen_string_literal: true
+
+class MigrateIncidentIssuesToIncidentType < ActiveRecord::Migration[6.0]
+ DOWNTIME = false
+ BATCH_SIZE = 100
+
+ disable_ddl_transaction!
+
+ LABEL_PROPERTIES = {
+ title: 'incident'
+ }.freeze
+
+ class Issue < ActiveRecord::Base
+ include EachBatch
+
+ self.table_name = 'issues'
+
+ scope :incident_labelled, -> do
+ joins("INNER JOIN label_links ON label_links.target_type = 'Issue' AND label_links.target_id = issues.id")
+ .joins("INNER JOIN labels ON labels.id = label_links.label_id")
+ .where(labels: LABEL_PROPERTIES)
+ end
+
+ enum issue_type: {
+ issue: 0,
+ incident: 1
+ }
+
+ scope :incident_typed, -> { where(issue_type: :incident) }
+ end
+
+ def up
+ incident_issues = Issue.incident_labelled
+
+ incident_issues.each_batch(of: BATCH_SIZE) do |batch|
+ batch.update_all(issue_type: :incident)
+ end
+ end
+
+ def down
+ incident_issues = Issue.incident_typed
+
+ incident_issues.each_batch(of: BATCH_SIZE) do |batch|
+ batch.update_all(issue_type: :issue)
+ end
+ end
+end
diff --git a/db/schema_migrations/20200723040950 b/db/schema_migrations/20200723040950
new file mode 100644
index 00000000000..fc2233ef119
--- /dev/null
+++ b/db/schema_migrations/20200723040950
@@ -0,0 +1 @@
+085b3ad0f7da78a1e13f5cd3d2e7df297284a682c3bcd3883e487b18497430ff \ No newline at end of file
diff --git a/doc/development/i18n/externalization.md b/doc/development/i18n/externalization.md
index 4838a24fb9d..f8c20bd06c9 100644
--- a/doc/development/i18n/externalization.md
+++ b/doc/development/i18n/externalization.md
@@ -650,6 +650,10 @@ aren't in the message with ID `1 pipeline`.
## Adding a new language
+NOTE: **Note:**
+[Introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/221012) in GitLab 13.3:
+Languages with less than 2% of translations won't be available in the UI.
+
Let's suppose you want to add translations for a new language, let's say French.
1. The first step is to register the new language in `lib/gitlab/i18n.rb`:
diff --git a/lib/gitlab/git/pre_receive_error.rb b/lib/gitlab/git/pre_receive_error.rb
index ef9b1bf5224..7a6f27179f0 100644
--- a/lib/gitlab/git/pre_receive_error.rb
+++ b/lib/gitlab/git/pre_receive_error.rb
@@ -16,8 +16,16 @@ module Gitlab
SAFE_MESSAGE_REGEX = /^(#{SAFE_MESSAGE_PREFIXES.join('|')})\s*(?<safe_message>.+)/.freeze
- def initialize(message = '')
- super(sanitize(message))
+ attr_reader :raw_message
+
+ def initialize(message = '', user_message = '')
+ @raw_message = message
+
+ if user_message.present?
+ super(sanitize(user_message))
+ else
+ super(sanitize(message))
+ end
end
private
diff --git a/lib/gitlab/gitaly_client/operation_service.rb b/lib/gitlab/gitaly_client/operation_service.rb
index f53156bac82..513063c60d2 100644
--- a/lib/gitlab/gitaly_client/operation_service.rb
+++ b/lib/gitlab/gitaly_client/operation_service.rb
@@ -179,7 +179,7 @@ module Gitlab
)
if response.pre_receive_error.present?
- raise Gitlab::Git::PreReceiveError.new("GL-HOOK-ERR: pre-receive hook failed.")
+ raise Gitlab::Git::PreReceiveError.new(response.pre_receive_error, "GL-HOOK-ERR: pre-receive hook failed.")
end
Gitlab::Git::OperationService::BranchUpdate.from_gitaly(response.branch_update)
diff --git a/lib/gitlab/i18n.rb b/lib/gitlab/i18n.rb
index 18f4cb559c5..3b19ae3d7ff 100644
--- a/lib/gitlab/i18n.rb
+++ b/lib/gitlab/i18n.rb
@@ -4,6 +4,20 @@ module Gitlab
module I18n
extend self
+ # Languages with less then 2% of available translations will not
+ # be available in the UI.
+ # https://gitlab.com/gitlab-org/gitlab/-/issues/221012
+ NOT_AVAILABLE_IN_UI = %w[
+ fil_PH
+ pl_PL
+ nl_NL
+ id_ID
+ cs_CZ
+ bg
+ eo
+ gl_ES
+ ].freeze
+
AVAILABLE_LANGUAGES = {
'bg' => 'Bulgarian - български',
'cs_CZ' => 'Czech - čeština',
@@ -29,6 +43,10 @@ module Gitlab
'zh_TW' => 'Chinese, Traditional (Taiwan) - 繁體中文 (台灣)'
}.freeze
+ def selectable_locales
+ AVAILABLE_LANGUAGES.reject { |key, _value| NOT_AVAILABLE_IN_UI.include? key }
+ end
+
def available_locales
AVAILABLE_LANGUAGES.keys
end
diff --git a/lib/gitlab/i18n/html_todo.yml b/lib/gitlab/i18n/html_todo.yml
index b54a722eae8..5dbc2dbaf61 100644
--- a/lib/gitlab/i18n/html_todo.yml
+++ b/lib/gitlab/i18n/html_todo.yml
@@ -74,9 +74,6 @@
- "< 1 hora"
- "< 1 saat"
- "< 1 Stunde"
-"<strong>%{label_name}</strong> <span>will be permanently deleted from %{subject_name}. This cannot be undone.</span>":
- plural_id:
- translations:
"<strong>Deletes</strong> source branch":
plural_id:
translations:
@@ -107,13 +104,6 @@
- "Vous êtes sur le point de supprimer ce badge. Les badges supprimés <strong>ne peuvent pas</strong> être restaurés."
- "Va a eliminar esta insignia. Las insignias eliminadas <strong>no se pueden</strong> restaurar."
- "Bu rozeti sileceksiniz. Silinen rozetler geri <strong>yüklenemez</strong>."
-"BillingPlans|Your GitLab.com %{plan} trial will <strong>expire after %{expiration_date}</strong>. You can retain access to the %{plan} features by upgrading below.":
- plural_id:
- translations:
- - "GitLab.com の %{plan} の試用版は、<strong>%{expiration_date}後に有効期限が切れます</strong>。 以下をアップグレードして、%{plan} の機能へのアクセスをそのままにできます。"
- - "您的GitLab.com%{plan}试用将在<strong>%{expiration_date}过期</strong>。您可以通过以下方式升级以保留对%{plan}功能的访问权限。"
- - "Ваш пробний період використання GitLab.com %{plan} закінчується <strong>%{expiration_date}</strong>. Ви можете зберегти доступ до функцій %{plan} шляхом оновленням нижче."
- - "Su periodo de prueba de GitLab.com %{plan} <strong>caducará después del %{expiration_date}</strong>. Puede conservar el acceso a las %{plan} funciones actualizando la versión %{plan} de GitLab.com a continuación."
"Branch <strong>%{branch_name}</strong> was created. To set up auto deploy, choose a GitLab CI Yaml template and commit your changes. %{link_to_autodeploy_doc}":
plural_id:
translations:
@@ -137,13 +127,6 @@
- "これにより、次のリソースは完全に削除されます <ul> <li>インストールされているすべてのアプリケーションと関連したリソース</li> <li> <code>gitlab-managed-apps</code> 名前空間</li> <li>任意のプロジェクト名前空間</li> <li><code>clusterroles</code></li> <li><code>clusterrolebindings</code></li> </ul>"
- "此操作将永久删除下列资源: <ul> <li>所有已安装的应用程序和相关资源</li> <li> <code>GitLab管理的应用</code> 命名空间</li> <li>任何项目命名空间</li> <li><code>clusterroles</code></li> <li><code>clusterrolebindings</code></li> </ul>"
- "Esto eliminará permanentemente los siguientes recursos: <ul> <li>Todas las aplicaciones instaladas y sus recursos relacionados</li> <li>El espacio de nombres <code>gitlab-managed-apps</code></li> <li>Cualquier espacio de nombres de proyecto</li> <li><code> clusterroles </code></li> <li><code>clusterrolebindings</code></li> </ul>"
-"ClusterIntegration|A cluster management project can be used to run deployment jobs with Kubernetes <code>cluster-admin</code> privileges.":
- plural_id:
- translations:
- - "クラスター管理プロジェクトを使用して、Kubernetes <code> cluster-admin </code>特権で展開ジョブを実行できます。"
- - "Проект управления кластером можно использовать для запуска заданий развертывания с привилегиями Kubernetes <code>cluster-admin</code>."
- - "集群管理的项目可以通过Kubernetes<code>cluster-admin</code>权限来运行部署作业。"
- - "Проєкт управління кластером може використовуватися для виконання завдань розгортання з привілеями Kubernetes <code>cluster-admin</code>."
"Configure a <code>.gitlab-webide.yml</code> file in the <code>.gitlab</code> directory to start using the Web Terminal. %{helpStart}Learn more.%{helpEnd}":
plural_id:
translations:
@@ -154,35 +137,6 @@
- "Налаштуйте файл <code>.gitlab-webide.yml</code> у директорії <code>.gitlab</code>, щоб почати використовувати Веб-термінал. %{helpStart}Докладніше.%{helpEnd}"
- "웹 터미널 사용을 시작하도록 <code>.gitlab</code> 디렉토리에서 <code>.gitlab-webide.yml</code> 파일을 구성하십시오. %{helpStart}자세히 알아보십시오.%{helpEnd}"
- "Configure un archivo <code>.gitlab-webide.yml</code> en el directorio <code>.gitlab</code> para comenzar a utilizar el Terminal Web. %{helpStart}Aprende más.%{helpEnd}"
-"ContributionAnalytics|<strong>%{created_count}</strong> created, <strong>%{closed_count}</strong> closed.":
- plural_id:
- translations:
- - "<strong>%{created_count}</strong> 件を作成、<strong>%{closed_count}</strong>件をクローズしました。"
- - "已创建<strong>%{created_count}</strong> 个,已关闭<strong>%{closed_count}</strong>个。"
- - "<strong>%{created_count}</strong> створено, <strong>%{closed_count}</strong> закрито."
- - "<strong>%{created_count}</strong> creado, <strong>%{closed_count}</strong> cerrado."
- - "<strong>%{created_count}</strong> oluşturuldu, <strong>%{closed_count}</strong> kapatıldı."
-"ContributionAnalytics|<strong>%{created_count}</strong> created, <strong>%{merged_count}</strong> merged.":
- plural_id:
- translations:
-"ContributionAnalytics|<strong>%{pushes}</strong> pushes, more than <strong>%{commits}</strong> commits by <strong>%{people}</strong> contributors.":
- plural_id:
- translations:
- - "<strong>%{pushes}</strong>回のプッシュ、<strong>%{commits}</strong>回以上のコミットが貢献者<strong>%{people}</strong>によって行われました。"
- - "<strong>%{pushes}</strong>次推送,含来自<strong>%{people}</strong>位贡献者的<strong>%{commits}</strong>次以上提交。"
- - "<strong>%{pushes}</strong> отправок — больше чем <strong>%{commits}</strong> коммитов от <strong>%{people}</strong> участников."
-"Contributions for <strong>%{calendar_date}</strong>":
- plural_id:
- translations:
- - "Contribuições para <strong>%{calendar_date}</strong>"
- - "<strong>%{calendar_date}</strong>の貢献"
- - "<strong>%{calendar_date}</strong>的贡献"
- - "Внески за <strong>%{calendar_date}</strong>"
- - "Beiträge am <strong>%{calendar_date}</strong>"
- - "<strong>%{calendar_date}</strong>의 기여도"
- - "Contributions du <strong>%{calendar_date}</strong>"
- - "Contribuciones para <strong>%{calendar_date}</strong>"
- - "<strong>%{calendar_date}</strong> için katkılar"
"Depends on <strong>%d closed</strong> merge request.":
plural_id: "Depends on <strong>%d closed</strong> merge requests."
translations:
@@ -208,47 +162,6 @@
"Example: <code>acme.com,acme.co.in,acme.uk</code>.":
plural_id:
translations:
-"Fill in the fields below, turn on <strong>%{enable_label}</strong>, and press <strong>%{save_changes}</strong>":
- plural_id:
- translations:
- - "Preencha nos campos abaixo, ative o <strong>%{enable_label}</strong> e pressione <strong>%{save_changes}</strong>"
- - "下記項目に必要事項を入力し、 <strong>%{enable_label}</strong>をオンにして、 <strong>%{save_changes}</strong>を押してください。"
- - "填写下面的字段,启用<strong>%{enable_label}</strong>,然后点击<strong>%{save_changes}</strong>"
- - "Заповніть поля нижче, увімкніть <strong>%{enable_label}</strong> та натисніть <strong>%{save_changes}</strong>"
- - "Fülle die Felder unten aus, schalte <strong>%{enable_label}</strong> an, und drücke <strong>%{save_changes}</strong>"
- - "Renseignez les champs ci‐dessous, activez <strong>%{enable_label}</strong> et appuyez sur <strong>%{save_changes}</strong>"
- - "Rellene los siguientes campos, active <strong>%{enable_label}</strong>y presione <strong>%{save_changes}</strong>"
-"Finish setting up your dedicated account for <strong>%{group_name}</strong>.":
- plural_id:
- translations:
- - "Termine de configurar sua conta dedicada para <strong>%{group_name}</strong>."
- - "<strong>%{group_name} </strong>の専用アカウントの設定を完了してください。"
- - "Завершите настройку вашей учетной записи для <strong>%{group_name}</strong>."
- - "完成您的<strong>%{group_name}</strong>专用帐户设置。"
- - "Завершіть налаштування вашого виділеного облікового запису для <strong>%{group_name}</strong>."
- - "Finalizar la configuración de su cuenta dedicada para <strong>%{group_name}</strong>."
-"Geo|You are on a secondary, <b>read-only</b> Geo node. If you want to make changes, you must visit this page on the %{primary_node}.":
- plural_id:
- translations:
- - "Você está em um nó Geo secundário <b>somente para leitura</b>. Se você quiser fazer mudanças, você deve visitar essa página no %{primary_node}."
- - "あなたは<b>読み取り専用の</b>セカンダリGeoノードにいます。変更を加えたい場合は、%{primary_node} のこのページにアクセスする必要があります。"
- - "Вы находитесь на вторичном узле Geo в режиме <b>только для чтения</b>. Если вы хотите внести изменения, вы должны зайти на эту же страницу на %{primary_node}."
- - "当前正在访问Geo次要 <b>只读 </b>节点。如需进行任何写入操作,必须访问%{primary_node}。"
- - "Ви знаходитесь на вторинному <b>лише для читання</b> Geo-вузлі. Якщо ви хочете внести будь-які зміни, ви повинні відвідати %{primary_node}."
- - "Du befindest dich auf einem sekundären, <b>read-only</b> Geo-Knoten. Um Änderungen vorzunehmen, musst du diese Seite auf dem %{primary_node} aufrufen."
- - "Vous êtes sur un nœud Geo secondaire <b>en lecture seule</b>. Si vous voulez apporter des modifications, vous devez le faire depuis cette page sur le %{primary_node}."
- - "Está en un nodo Geo secundario de <b>sólo lectura</b>. Si quiere realizar cambios, debe visitar esta página en %{primary_node}."
-"Geo|You are on a secondary, <b>read-only</b> Geo node. You may be able to make a limited amount of changes or perform a limited amount of actions on this page.":
- plural_id:
- translations:
- - "Você está em um nó Geo secundário <b>somente para leitura </b>. Você pode ser capaz de fazer um número limitado de mudanças ou executar uma quantidade limitada de ações nessa página."
- - "あなたは<b>読み取り専用の</b>セカンダリGeoノードにいます。このページでは限定的な変更・操作をすることができます。"
- - "Вы находитесь на вторичном, доступном <b>только для чтения</b>, узле Geo. Вы можете осуществлять ограниченное количество изменений и действий на данной странице."
- - "当前正在访问Geo次要 <b>只读 </b>节点。您可以在此页面上进行有限的更改或执行有限的操作。"
- - "Ви знаходитесь на вторинному <b>лише для читання</b> Geo-вузлі. Ви зможете вносити лише обмежену кількість змін та виконувати обмежений набір операцій з цієї сторінки."
- - "Du befindest dich auf einem sekundären, <b>read-only</b> Geo-Knoten. Möglicherweise kannst du nur eine begrenzte Anzahl an Änderungen oder Aktionen auf dieser Seite durchführen."
- - "Vous êtes sur un nœud Geo secondaire <b>en lecture seule</b>. Nous ne pourrez effectuer que des modifications ou des actions limitées depuis cette page."
- - "Está en un nodo secundario, <b>de solo lectura</b> Geo. Es posible que pueda realizar una cantidad limitada de cambios o realizar una cantidad limitada de acciones en esta página."
"Git LFS objects will be synced in pull mirrors if LFS is %{docs_link_start}enabled for the project%{docs_link_end}. They will <strong>not</strong> be synced in push mirrors.":
plural_id:
translations:
@@ -274,19 +187,6 @@
"Go to <strong>Issues</strong> > <strong>Boards</strong> to access your personalized learning issue board.":
plural_id:
translations:
-"In order to personalize your experience with GitLab<br>we would like to know a bit more about you.":
- plural_id:
- translations:
- - "Для того, чтобы адаптировать ваш опыт работы с GitLab<br>, мы хотели бы узнать о вас немного больше."
- - "Con el fin de adaptar su experiencia con GitLab<br>nos gustaría saber un poco más sobre usted."
- - "Для того, щоб персоналізувати ваш досвід роботи з GitLab<br>,ми хотіли б дізнатися більше про вас."
-"In order to tailor your experience with GitLab we<br>would like to know a bit more about you.":
- plural_id:
- translations:
- - "GitLabでの経験を調整するために、<br>もう少しあなたについて知りたいです。"
- - "为了能量身定制您在GitLab的体验,我们<br>希望对您有更多了解。"
- - "Для того, щоб адаптувати GitLab до вас нам<br>потрібно більше про вас дізнатися."
- - "Para personalizar su experiencia con GitLab <br>nos gustaría conocer un poco más sobre usted."
"Include the username in the URL if required: <code>https://username@gitlab.company.com/group/project.git</code>.":
plural_id:
translations:
@@ -341,13 +241,6 @@
- "Учасники <strong>%{project_name}</strong>"
- "Miembros de <strong>%{project_name}</strong>"
- "<strong>%{project_name}</strong> projesinin üyeleri"
-"Please refer to <a href=\\\"%{docs_url}\\\">%{docs_url}</a>":
- plural_id:
- translations:
- - "<a href=\\\"%{docs_url}\\\">%{docs_url}</a>を参照してください"
- - "请参考<a href=\\\"%{docs_url}\\\">%{docs_url}</a>"
- - "Будь ласка перегляньте <a href=\\\"%{docs_url}\\\">%{docs_url}</a>"
- - "Por favor, consulte <a href=\\\"%{docs_url}\\\">%{docs_url}</a>"
"PrometheusService|<p class=\\\"text-tertiary\\\">No <a href=\\\"%{docsUrl}\\\">common metrics</a> were found</p>":
plural_id:
translations:
@@ -360,40 +253,6 @@
- "<p class=\\\"text-tertiary\\\"><a href=\\\"%{docsUrl}\\\">공통 메트릭스</a>가 발견되지 않았습니다.</p>"
- "<p class=\\\"text-tertiary\\\">Aucune <a href=\\\"%{docsUrl}\\\">métrique commune</a> trouvée</p>"
- "<p class=\\\"text-tertiary\\\">No se han encontrado<a href=\\\"%{docsUrl}\\\">métricas comunes</a> </p>"
-"SSH host keys are not available on this system. Please use <code>ssh-keyscan</code> command or contact your GitLab administrator for more information.":
- plural_id:
- translations:
- - "このシステムでは SSH ホスト鍵は使用できません。 <code>ssh-keyscan</code> コマンドを使用するか、GitLab の管理者に詳細をお問い合わせください。"
- - "Ключи SSH хоста недоступны в этой системе. Пожалуйста, используйте команду <code>ssh-keyscan</code> или свяжитесь со своим администратором GitLab для получения дополнительной информации."
- - "SSH主机密钥在此系统上不可用。请使用<code>ssh-keyscan</code>命令或与您的GitLab管理员联系以获取更多信息。"
- - "SSH-ключі хоста не доступні в цій системі. Будь ласка, використовуйте команду <code>ssh-keyscan</code> або зверніться до вашого адміністратора GitLab для додаткової інформації."
- - "Las claves SSH del host no se encuentran disponibles en este sistema. Utilice el comando <code>ssh-keyscan</code> o póngase en contacto con su administrador de GitLab para obtener más información."
-"Share the <strong>%{sso_label}</strong> with members so they can sign in to your group through your identity provider":
- plural_id:
- translations:
- - "Compartilhe o <strong>%{sso_label}</strong> com membros de forma que eles possam entrar em seu grupo por meio de seu provedor de identidade"
- - "メンバーと<strong>%{sso_label}</strong>を共有すると、自身の ID プロバイダーでサインインすることができます"
- - "分享<strong>%{sso_label}</strong> 给组员,以便他们可以通过您的身份提供商登录您的群组"
- - "Поділіться <strong>%{sso_label}</strong> із учасниками для того, щоб вони могли увійти до вашої групи через провайдера ідентифікації"
- - "Teile das <strong>%{sso_label}</strong> mit Mitgliedern, damit sie sich über deinen Identitätsanbieter bei deiner Gruppe anmelden können"
- - "회원과 <strong>%{sso_label}</strong> 항목을 공유해 신원 제공 업체를 통해 그룹에 로그인할 수 있도록 합니다."
- - "Partager le <strong>%{sso_label}</strong> avec les membres afin qu’ils puissent se connecter à votre groupe via votre fournisseur d’identité"
- - "Comparta <strong>%{sso_label}</strong> con los diferentes miembros para que puedan iniciar sesión en su grupo a través de su proveedor de identidad"
-"Speed up your DevOps<br>with GitLab":
- plural_id:
- translations:
- - "Acelere sus DevOps<br>con GitLab"
-"The Git LFS objects will <strong>not</strong> be synced.":
- plural_id:
- translations:
- - "Os objetos LFS do Git <strong>não</strong> serão sincronizados."
- - "Git の LFS オブジェクトは<strong>同期しません</strong>。"
- - "Git LFS对象将<strong>不会</strong>被同步。"
- - "Об'єкти Git LFS <strong>не</strong> будуть синхронізуватися."
- - "Die Git LFS-Objekte werden <strong>nicht</strong> synchronisiert werden."
- - "Les objets Git LFS <strong>ne sont pas</strong> synchronisés."
- - "Los objetos Git LFS <strong>no</strong> serán sincronizados."
- - "Obiekty Git LFS <strong>nie będą</strong> zsynchronizowane."
"The repository must be accessible over <code>http://</code>, <code>https://</code>, <code>ssh://</code> or <code>git://</code>.":
plural_id:
translations:
@@ -402,14 +261,6 @@
- "该仓库必须可通过 <code>http://</code>,<code>https://</code>,<code>ssh://</code> 或 <code>git://</code>进行访问。"
- "Репозиторій має бути доступним через <code>http://</code>, <code>https://</code>, <code>ssh://</code> or <code>git://</code>."
- "El repositorio debe ser accesible a través de <code>http://</code>, <code>https://</code>, <code>ssh://</code> y <code>git://</code>."
-"This %{issuable} is locked. Only <strong>project members</strong> can comment.":
- plural_id:
- translations:
- - "この %{issuable} はロックされています。<strong>プロジェクトメンバー</strong> だけがコメントできます。"
- - "Этот %{issuable} заблокировано. Только <strong>участники проекта</strong> могут комментировать."
- - "此%{issuable}已被锁定。只有<strong>项目成员</strong>可以发表评论。"
- - "Ця %{issuable} заблокована. Лише <strong>учасники проекту</strong> можуть коментувати."
- - "Este %{issuable} está bloqueado. Solo los <strong>miembros del proyecto</strong> pueden comentar."
"This group, including all subgroups, projects and git repositories, will only be reachable from the specified IP address range. Multiple addresses are supported with comma delimiters.<br>Example: <code>192.168.0.0/24,192.168.1.0/24</code>. %{read_more_link}.":
plural_id:
translations:
@@ -439,19 +290,6 @@
- "%{issuableDisplayName}(을)를 잠금해제 하시겠습니까? <strong>모두가</strong> 코멘트 할 수 있게 됩니다."
- "Déverrouiller %{issuableDisplayName} ? <strong>Tout le monde</strong> sera en mesure de commenter."
- "Desbloquear este %{issuableDisplayName}? <strong>Todos</strong> podrán comentar."
-"Upon performing this action, the contents of this group, its subgroup and projects will be permanently removed after %{deletion_adjourned_period} days on <strong>%{date}</strong>. Until that time:":
- plural_id:
- translations:
-"Use <code>%{native_redirect_uri}</code> for local tests":
- plural_id:
- translations:
- - "Use <code>%{native_redirect_uri}</code> para testes locais"
- - "ローカルテストに <code>%{native_redirect_uri}</code> を使用"
- - "使用<code>%{native_redirect_uri}</code>进行本地测试"
- - "Використовувати <code>%{native_redirect_uri}</code> для локальних тестів"
- - "Verwende <code>%{native_redirect_uri}</code> für lokale Tests"
- - "Utiliser <code>%{native_redirect_uri}</code> pour les tests locaux"
- - "Use <code>%{native_redirect_uri}</code> para los tests locales"
"UserOnboardingTour|Issues are great for communicating and keeping track of progress in GitLab. These are all issues that are open in the %{emphasisStart}%{projectName}%{emphasisEnd}.%{lineBreak}%{lineBreak}You can help us improve GitLab by contributing work to issues that are labeled <span class=\\\"badge color-label accept-mr-label\\\">Accepting merge requests</span>.%{lineBreak}%{lineBreak}This list can be filtered by labels, milestones, assignees, authors... We'll show you how it looks when the list is filtered by a label.":
plural_id:
translations:
@@ -459,25 +297,6 @@
- "Обсуждения в GitLab отлично подходят для коммуникации и отслеживания прогресса. Перед вами все обсуждения, открытые в %{emphasisStart}%{projectName}%{emphasisEnd}.%{lineBreak}%{lineBreak}Вы можете помочь нам улучшить GitLab, приняв участие в работе над обсуждениями с меткой <span class=\\\"badge color-label accept-mr-label\\\">Accepting merge requests</span> (принимаются запросы на слияние).%{lineBreak}%{lineBreak}Этот список может быть отфильтрован по меткам, этапам, испонителям, авторам... Мы покажем вам, как выглядит отфильтрованный по метке список."
- "议题非常适合在GitLab中进行沟通和跟踪进展。这些是在%{emphasisStart}%{projectName}%{emphasisEnd}中开启的全部议题。%{lineBreak}%{lineBreak}您可以通过为标记为<span class=\\\"badge color-label accept-mr-label\\\">Accepting merge requests</span>的议题作出贡献来帮助我们改进GitLab。%{lineBreak}%{lineBreak}此列表可以按标签,里程碑,受让人,作者进行过滤......我们将向您展示列表按标签过滤时的样子。"
- "Задачі добре підходять для комунікації та відстеження прогресу в GitLab. Ось задачі, які відкриті в %{emphasisStart}%{projectName}%{emphasisEnd}.%{lineBreak}%{lineBreak}Ви можете допомогти нам покращити GitLab шляхом внесків у задачі, що відмічені <span class=\\\"badge color-label accept-mr-label\\\">Приймаються запити на злиття</span>.%{lineBreak}%{lineBreak}Цей список може бути відвільтрований за мітками, етапами, виконавцями, авторами... Ми продоемонструємо як виглядає список, відфільтрований за міткою."
-"Welcome to GitLab.com<br>@%{name}!":
- plural_id:
- translations:
- - "Добро пожаловать в GitLab.com<br>@%{name}!"
- - "Ласкаво просимо до GitLab.com<br>@%{name}!"
- - "¡Bienvenido a GitLab.com<br>@%{name}!"
-"WikiMarkdownTip|To link to a (new) page, simply type <code class=\\\"js-markup-link-example\\\">%{link_example}</code>":
- plural_id:
- translations:
-"You are an admin, which means granting access to <strong>%{client_name}</strong> will allow them to interact with GitLab as an admin as well. Proceed with caution.":
- plural_id:
- translations:
- - "Você é um administrador, o que significa que conceder acesso a <strong>%{client_name}</strong> permitirá que eles também interajam com o GitLab como administrador. Prossiga com cuidado."
- - "あなたは管理者です。つまり、 <strong>%{client_name}</strong> へのアクセスを許可すると、それは管理者としてGitLabとやりとりできます。注意してください。"
- - "您是一名管理员,这意味着授予对 <strong>%{client_name}</strong> 访问权限将允许他们作为管理员与GitLab进行交互。请谨慎操作。"
- - "Ви — адміністратор, а це означає, що надання доступу для <strong>%{client_name}</strong> дозволить їм взаємодіяти з GitLab як адміністратору. Продовжуйте обережно."
- - "Du bist Administrator(in). Wenn du <strong>%{client_name}</strong> Zugriff gewährst, wird es auch als Administrator mit GitLab interagieren können. Mit Vorsicht fortfahren."
- - "Vous êtes un administrateur ou une administratrice, ce qui signifie qu’accorder un accès à <strong>%{client_name}</strong> lui permettra d’interagir avec GitLab en tant qu’administrateur également. Faites‐le avec prudence."
- - "Es administrador, lo que significa que otorgar acceso a <strong>%{client_name}</strong> le permitirá interactuar con GitLab como también administrador. Por favor, proceda con precaución."
"You can invite a new member to <strong>%{project_name}</strong> or invite another group.":
plural_id:
translations:
@@ -506,13 +325,6 @@
- "您可以邀请另一个群组加入<strong>%{project_name}</strong>。"
- "Ви можете запросити нову групу до <strong>%{project_name}</strong>."
- "Puedes invitar a otro grupo a <strong>%{project_name}</strong>."
-"You may also add variables that are made available to the running application by prepending the variable key with <code>K8S_SECRET_</code>.":
- plural_id:
- translations:
- - "変数名の前に <code>K8S_SECRET_</code>を指定することで、実行中のアプリケーションで使用する変数を追加することもできます。"
- - "您还可以通过在变量键前面加上<code>K8S_SECRET_</code>来添加可用于正在运行的应用程序的变量。"
- - "Ви також можете додати змінні, що будуть доступними для запущеного застосунку шляхом додавання префіксу <code>K8S_SECRET_</code> до їх імен."
- - "También puede añadir variables que están disponibles para la aplicación en ejecución, anteponiendo la clave de variable con <code>K8S_SECRET_</code>."
"confidentiality|You are going to turn off the confidentiality. This means <strong>everyone</strong> will be able to see and leave a comment on this issue.":
plural_id:
translations:
@@ -696,6 +508,23 @@
"Your license will be included in your GitLab backup and will survive upgrades, so in normal usage you should never need to re-upload your <code>.gitlab-license</code> file.":
plural_id:
translations:
+"ContributionAnalytics|<strong>%{pushes}</strong> pushes, more than <strong>%{commits}</strong> commits by <strong>%{people}</strong> contributors.":
+ plural_id:
+ translations:
+ - "<strong>%{pushes}</strong>回のプッシュ、<strong>%{commits}</strong>回以上のコミットが貢献者<strong>%{people}</strong>によって行われました。"
+ - "<strong>%{pushes}</strong>次推送,含来自<strong>%{people}</strong>位贡献者的<strong>%{commits}</strong>次以上提交。"
+ - "<strong>%{pushes}</strong> отправок — больше чем <strong>%{commits}</strong> коммитов от <strong>%{people}</strong> участников."
+"ContributionAnalytics|<strong>%{created_count}</strong> created, <strong>%{closed_count}</strong> closed.":
+ plural_id:
+ translations:
+ - "<strong>%{created_count}</strong> 件を作成、<strong>%{closed_count}</strong>件をクローズしました。"
+ - "已创建<strong>%{created_count}</strong> 个,已关闭<strong>%{closed_count}</strong>个。"
+ - "<strong>%{created_count}</strong> створено, <strong>%{closed_count}</strong> закрито."
+ - "<strong>%{created_count}</strong> creado, <strong>%{closed_count}</strong> cerrado."
+ - "<strong>%{created_count}</strong> oluşturuldu, <strong>%{closed_count}</strong> kapatıldı."
+"ContributionAnalytics|<strong>%{created_count}</strong> created, <strong>%{merged_count}</strong> merged.":
+ plural_id:
+ translations:
"<code>\\\"johnsmith@example.com\\\": \\\"@johnsmith\\\"</code> will add \\\"By <a href=\\\"#\\\">@johnsmith</a>\\\" to all issues and comments originally created by johnsmith@example.com, and will set <a href=\\\"#\\\">@johnsmith</a> as the assignee on all issues originally assigned to johnsmith@example.com.":
plural_id:
translations:
@@ -1053,3 +882,174 @@
- "Выберите флажок <strong>Активный</strong>, нажмите на <strong>Сохранить изменения</strong> и начните использовать GitLab внутри Slack!"
- "3. 选择<strong>Active</strong>复选框,点击<strong>Save change</strong>后开始在Slack中使用GitLab!"
- "3. Встановіть прапорець в пункті <strong>Активний</strong>, натисніть <strong>Зберегти зміни</strong> та починайте використовувати GitLab в Slack!"
+"Finish setting up your dedicated account for <strong>%{group_name}</strong>.":
+ plural_id:
+ translations:
+ - "Termine de configurar sua conta dedicada para <strong>%{group_name}</strong>."
+ - "<strong>%{group_name} </strong>の専用アカウントの設定を完了してください。"
+ - "Завершите настройку вашей учетной записи для <strong>%{group_name}</strong>."
+ - "完成您的<strong>%{group_name}</strong>专用帐户设置。"
+ - "Завершіть налаштування вашого виділеного облікового запису для <strong>%{group_name}</strong>."
+ - "Finalizar la configuración de su cuenta dedicada para <strong>%{group_name}</strong>."
+"Fill in the fields below, turn on <strong>%{enable_label}</strong>, and press <strong>%{save_changes}</strong>":
+ plural_id:
+ translations:
+ - "Preencha nos campos abaixo, ative o <strong>%{enable_label}</strong> e pressione <strong>%{save_changes}</strong>"
+ - "下記項目に必要事項を入力し、 <strong>%{enable_label}</strong>をオンにして、 <strong>%{save_changes}</strong>を押してください。"
+ - "填写下面的字段,启用<strong>%{enable_label}</strong>,然后点击<strong>%{save_changes}</strong>"
+ - "Заповніть поля нижче, увімкніть <strong>%{enable_label}</strong> та натисніть <strong>%{save_changes}</strong>"
+ - "Fülle die Felder unten aus, schalte <strong>%{enable_label}</strong> an, und drücke <strong>%{save_changes}</strong>"
+ - "Renseignez les champs ci‐dessous, activez <strong>%{enable_label}</strong> et appuyez sur <strong>%{save_changes}</strong>"
+ - "Rellene los siguientes campos, active <strong>%{enable_label}</strong>y presione <strong>%{save_changes}</strong>"
+"Share the <strong>%{sso_label}</strong> with members so they can sign in to your group through your identity provider":
+ plural_id:
+ translations:
+ - "Compartilhe o <strong>%{sso_label}</strong> com membros de forma que eles possam entrar em seu grupo por meio de seu provedor de identidade"
+ - "メンバーと<strong>%{sso_label}</strong>を共有すると、自身の ID プロバイダーでサインインすることができます"
+ - "分享<strong>%{sso_label}</strong> 给组员,以便他们可以通过您的身份提供商登录您的群组"
+ - "Поділіться <strong>%{sso_label}</strong> із учасниками для того, щоб вони могли увійти до вашої групи через провайдера ідентифікації"
+ - "Teile das <strong>%{sso_label}</strong> mit Mitgliedern, damit sie sich über deinen Identitätsanbieter bei deiner Gruppe anmelden können"
+ - "회원과 <strong>%{sso_label}</strong> 항목을 공유해 신원 제공 업체를 통해 그룹에 로그인할 수 있도록 합니다."
+ - "Partager le <strong>%{sso_label}</strong> avec les membres afin qu’ils puissent se connecter à votre groupe via votre fournisseur d’identité"
+ - "Comparta <strong>%{sso_label}</strong> con los diferentes miembros para que puedan iniciar sesión en su grupo a través de su proveedor de identidad"
+"<strong>%{label_name}</strong> <span>will be permanently deleted from %{subject_name}. This cannot be undone.</span>":
+ plural_id:
+ translations:
+"BillingPlans|Your GitLab.com %{plan} trial will <strong>expire after %{expiration_date}</strong>. You can retain access to the %{plan} features by upgrading below.":
+ plural_id:
+ translations:
+ - "GitLab.com の %{plan} の試用版は、<strong>%{expiration_date}後に有効期限が切れます</strong>。 以下をアップグレードして、%{plan} の機能へのアクセスをそのままにできます。"
+ - "您的GitLab.com%{plan}试用将在<strong>%{expiration_date}过期</strong>。您可以通过以下方式升级以保留对%{plan}功能的访问权限。"
+ - "Ваш пробний період використання GitLab.com %{plan} закінчується <strong>%{expiration_date}</strong>. Ви можете зберегти доступ до функцій %{plan} шляхом оновленням нижче."
+ - "Su periodo de prueba de GitLab.com %{plan} <strong>caducará después del %{expiration_date}</strong>. Puede conservar el acceso a las %{plan} funciones actualizando la versión %{plan} de GitLab.com a continuación."
+"ClusterIntegration|A cluster management project can be used to run deployment jobs with Kubernetes <code>cluster-admin</code> privileges.":
+ plural_id:
+ translations:
+ - "クラスター管理プロジェクトを使用して、Kubernetes <code> cluster-admin </code>特権で展開ジョブを実行できます。"
+ - "Проект управления кластером можно использовать для запуска заданий развертывания с привилегиями Kubernetes <code>cluster-admin</code>."
+ - "集群管理的项目可以通过Kubernetes<code>cluster-admin</code>权限来运行部署作业。"
+ - "Проєкт управління кластером може використовуватися для виконання завдань розгортання з привілеями Kubernetes <code>cluster-admin</code>."
+"Contributions for <strong>%{calendar_date}</strong>":
+ plural_id:
+ translations:
+ - "Contribuições para <strong>%{calendar_date}</strong>"
+ - "<strong>%{calendar_date}</strong>の貢献"
+ - "<strong>%{calendar_date}</strong>的贡献"
+ - "Внески за <strong>%{calendar_date}</strong>"
+ - "Beiträge am <strong>%{calendar_date}</strong>"
+ - "<strong>%{calendar_date}</strong>의 기여도"
+ - "Contributions du <strong>%{calendar_date}</strong>"
+ - "Contribuciones para <strong>%{calendar_date}</strong>"
+ - "<strong>%{calendar_date}</strong> için katkılar"
+"Geo|You are on a secondary, <b>read-only</b> Geo node. If you want to make changes, you must visit this page on the %{primary_node}.":
+ plural_id:
+ translations:
+ - "Você está em um nó Geo secundário <b>somente para leitura</b>. Se você quiser fazer mudanças, você deve visitar essa página no %{primary_node}."
+ - "あなたは<b>読み取り専用の</b>セカンダリGeoノードにいます。変更を加えたい場合は、%{primary_node} のこのページにアクセスする必要があります。"
+ - "Вы находитесь на вторичном узле Geo в режиме <b>только для чтения</b>. Если вы хотите внести изменения, вы должны зайти на эту же страницу на %{primary_node}."
+ - "当前正在访问Geo次要 <b>只读 </b>节点。如需进行任何写入操作,必须访问%{primary_node}。"
+ - "Ви знаходитесь на вторинному <b>лише для читання</b> Geo-вузлі. Якщо ви хочете внести будь-які зміни, ви повинні відвідати %{primary_node}."
+ - "Du befindest dich auf einem sekundären, <b>read-only</b> Geo-Knoten. Um Änderungen vorzunehmen, musst du diese Seite auf dem %{primary_node} aufrufen."
+ - "Vous êtes sur un nœud Geo secondaire <b>en lecture seule</b>. Si vous voulez apporter des modifications, vous devez le faire depuis cette page sur le %{primary_node}."
+ - "Está en un nodo Geo secundario de <b>sólo lectura</b>. Si quiere realizar cambios, debe visitar esta página en %{primary_node}."
+"Geo|You are on a secondary, <b>read-only</b> Geo node. You may be able to make a limited amount of changes or perform a limited amount of actions on this page.":
+ plural_id:
+ translations:
+ - "Você está em um nó Geo secundário <b>somente para leitura </b>. Você pode ser capaz de fazer um número limitado de mudanças ou executar uma quantidade limitada de ações nessa página."
+ - "あなたは<b>読み取り専用の</b>セカンダリGeoノードにいます。このページでは限定的な変更・操作をすることができます。"
+ - "Вы находитесь на вторичном, доступном <b>только для чтения</b>, узле Geo. Вы можете осуществлять ограниченное количество изменений и действий на данной странице."
+ - "当前正在访问Geo次要 <b>只读 </b>节点。您可以在此页面上进行有限的更改或执行有限的操作。"
+ - "Ви знаходитесь на вторинному <b>лише для читання</b> Geo-вузлі. Ви зможете вносити лише обмежену кількість змін та виконувати обмежений набір операцій з цієї сторінки."
+ - "Du befindest dich auf einem sekundären, <b>read-only</b> Geo-Knoten. Möglicherweise kannst du nur eine begrenzte Anzahl an Änderungen oder Aktionen auf dieser Seite durchführen."
+ - "Vous êtes sur un nœud Geo secondaire <b>en lecture seule</b>. Nous ne pourrez effectuer que des modifications ou des actions limitées depuis cette page."
+ - "Está en un nodo secundario, <b>de solo lectura</b> Geo. Es posible que pueda realizar una cantidad limitada de cambios o realizar una cantidad limitada de acciones en esta página."
+"In order to tailor your experience with GitLab we<br>would like to know a bit more about you.":
+ plural_id:
+ translations:
+ - "GitLabでの経験を調整するために、<br>もう少しあなたについて知りたいです。"
+ - "为了能量身定制您在GitLab的体验,我们<br>希望对您有更多了解。"
+ - "Для того, щоб адаптувати GitLab до вас нам<br>потрібно більше про вас дізнатися."
+ - "Para personalizar su experiencia con GitLab <br>nos gustaría conocer un poco más sobre usted."
+"Welcome to GitLab.com<br>@%{name}!":
+ plural_id:
+ translations:
+ - "Добро пожаловать в GitLab.com<br>@%{name}!"
+ - "Ласкаво просимо до GitLab.com<br>@%{name}!"
+ - "¡Bienvenido a GitLab.com<br>@%{name}!"
+"In order to personalize your experience with GitLab<br>we would like to know a bit more about you.":
+ plural_id:
+ translations:
+ - "Для того, чтобы адаптировать ваш опыт работы с GitLab<br>, мы хотели бы узнать о вас немного больше."
+ - "Con el fin de adaptar su experiencia con GitLab<br>nos gustaría saber un poco más sobre usted."
+ - "Для того, щоб персоналізувати ваш досвід роботи з GitLab<br>,ми хотіли б дізнатися більше про вас."
+"Please refer to <a href=\\\"%{docs_url}\\\">%{docs_url}</a>":
+ plural_id:
+ translations:
+ - "<a href=\\\"%{docs_url}\\\">%{docs_url}</a>を参照してください"
+ - "请参考<a href=\\\"%{docs_url}\\\">%{docs_url}</a>"
+ - "Будь ласка перегляньте <a href=\\\"%{docs_url}\\\">%{docs_url}</a>"
+ - "Por favor, consulte <a href=\\\"%{docs_url}\\\">%{docs_url}</a>"
+"SSH host keys are not available on this system. Please use <code>ssh-keyscan</code> command or contact your GitLab administrator for more information.":
+ plural_id:
+ translations:
+ - "このシステムでは SSH ホスト鍵は使用できません。 <code>ssh-keyscan</code> コマンドを使用するか、GitLab の管理者に詳細をお問い合わせください。"
+ - "Ключи SSH хоста недоступны в этой системе. Пожалуйста, используйте команду <code>ssh-keyscan</code> или свяжитесь со своим администратором GitLab для получения дополнительной информации."
+ - "SSH主机密钥在此系统上不可用。请使用<code>ssh-keyscan</code>命令或与您的GitLab管理员联系以获取更多信息。"
+ - "SSH-ключі хоста не доступні в цій системі. Будь ласка, використовуйте команду <code>ssh-keyscan</code> або зверніться до вашого адміністратора GitLab для додаткової інформації."
+ - "Las claves SSH del host no se encuentran disponibles en este sistema. Utilice el comando <code>ssh-keyscan</code> o póngase en contacto con su administrador de GitLab para obtener más información."
+"Speed up your DevOps<br>with GitLab":
+ plural_id:
+ translations:
+ - "Acelere sus DevOps<br>con GitLab"
+"The Git LFS objects will <strong>not</strong> be synced.":
+ plural_id:
+ translations:
+ - "Os objetos LFS do Git <strong>não</strong> serão sincronizados."
+ - "Git の LFS オブジェクトは<strong>同期しません</strong>。"
+ - "Git LFS对象将<strong>不会</strong>被同步。"
+ - "Об'єкти Git LFS <strong>не</strong> будуть синхронізуватися."
+ - "Die Git LFS-Objekte werden <strong>nicht</strong> synchronisiert werden."
+ - "Les objets Git LFS <strong>ne sont pas</strong> synchronisés."
+ - "Los objetos Git LFS <strong>no</strong> serán sincronizados."
+ - "Obiekty Git LFS <strong>nie będą</strong> zsynchronizowane."
+"This %{issuable} is locked. Only <strong>project members</strong> can comment.":
+ plural_id:
+ translations:
+ - "この %{issuable} はロックされています。<strong>プロジェクトメンバー</strong> だけがコメントできます。"
+ - "Этот %{issuable} заблокировано. Только <strong>участники проекта</strong> могут комментировать."
+ - "此%{issuable}已被锁定。只有<strong>项目成员</strong>可以发表评论。"
+ - "Ця %{issuable} заблокована. Лише <strong>учасники проекту</strong> можуть коментувати."
+ - "Este %{issuable} está bloqueado. Solo los <strong>miembros del proyecto</strong> pueden comentar."
+"Upon performing this action, the contents of this group, its subgroup and projects will be permanently removed after %{deletion_adjourned_period} days on <strong>%{date}</strong>. Until that time:":
+ plural_id:
+ translations:
+"Use <code>%{native_redirect_uri}</code> for local tests":
+ plural_id:
+ translations:
+ - "Use <code>%{native_redirect_uri}</code> para testes locais"
+ - "ローカルテストに <code>%{native_redirect_uri}</code> を使用"
+ - "使用<code>%{native_redirect_uri}</code>进行本地测试"
+ - "Використовувати <code>%{native_redirect_uri}</code> для локальних тестів"
+ - "Verwende <code>%{native_redirect_uri}</code> für lokale Tests"
+ - "Utiliser <code>%{native_redirect_uri}</code> pour les tests locaux"
+ - "Use <code>%{native_redirect_uri}</code> para los tests locales"
+"WikiMarkdownTip|To link to a (new) page, simply type <code class=\\\"js-markup-link-example\\\">%{link_example}</code>":
+ plural_id:
+ translations:
+"You are an admin, which means granting access to <strong>%{client_name}</strong> will allow them to interact with GitLab as an admin as well. Proceed with caution.":
+ plural_id:
+ translations:
+ - "Você é um administrador, o que significa que conceder acesso a <strong>%{client_name}</strong> permitirá que eles também interajam com o GitLab como administrador. Prossiga com cuidado."
+ - "あなたは管理者です。つまり、 <strong>%{client_name}</strong> へのアクセスを許可すると、それは管理者としてGitLabとやりとりできます。注意してください。"
+ - "您是一名管理员,这意味着授予对 <strong>%{client_name}</strong> 访问权限将允许他们作为管理员与GitLab进行交互。请谨慎操作。"
+ - "Ви — адміністратор, а це означає, що надання доступу для <strong>%{client_name}</strong> дозволить їм взаємодіяти з GitLab як адміністратору. Продовжуйте обережно."
+ - "Du bist Administrator(in). Wenn du <strong>%{client_name}</strong> Zugriff gewährst, wird es auch als Administrator mit GitLab interagieren können. Mit Vorsicht fortfahren."
+ - "Vous êtes un administrateur ou une administratrice, ce qui signifie qu’accorder un accès à <strong>%{client_name}</strong> lui permettra d’interagir avec GitLab en tant qu’administrateur également. Faites‐le avec prudence."
+ - "Es administrador, lo que significa que otorgar acceso a <strong>%{client_name}</strong> le permitirá interactuar con GitLab como también administrador. Por favor, proceda con precaución."
+"You may also add variables that are made available to the running application by prepending the variable key with <code>K8S_SECRET_</code>.":
+ plural_id:
+ translations:
+ - "変数名の前に <code>K8S_SECRET_</code>を指定することで、実行中のアプリケーションで使用する変数を追加することもできます。"
+ - "您还可以通过在变量键前面加上<code>K8S_SECRET_</code>来添加可用于正在运行的应用程序的变量。"
+ - "Ви також можете додати змінні, що будуть доступними для запущеного застосунку шляхом додавання префіксу <code>K8S_SECRET_</code> до їх імен."
+ - "También puede añadir variables que están disponibles para la aplicación en ejecución, anteponiendo la clave de variable con <code>K8S_SECRET_</code>."
diff --git a/locale/gitlab.pot b/locale/gitlab.pot
index aba3d6cbad9..28282a1da21 100644
--- a/locale/gitlab.pot
+++ b/locale/gitlab.pot
@@ -486,6 +486,9 @@ msgstr ""
msgid "%{label_for_message} unavailable"
msgstr ""
+msgid "%{label_name} %{span_open}will be permanently deleted from %{subject_name}. This cannot be undone.%{span_close}"
+msgstr ""
+
msgid "%{lets_encrypt_link_start}Let's Encrypt%{lets_encrypt_link_end} is a free, automated, and open certificate authority (CA), that give digital certificates in order to enable HTTPS (SSL/TLS) for websites."
msgstr ""
@@ -1037,9 +1040,6 @@ msgstr ""
msgid "<project name>"
msgstr ""
-msgid "<strong>%{label_name}</strong> <span>will be permanently deleted from %{subject_name}. This cannot be undone.</span>"
-msgstr ""
-
msgid "<strong>Deletes</strong> source branch"
msgstr ""
@@ -3780,7 +3780,7 @@ msgstr ""
msgid "BillingPlans|To manage the plan for this group, visit the billing section of %{parent_billing_page_link}."
msgstr ""
-msgid "BillingPlans|Your GitLab.com %{plan} trial will <strong>expire after %{expiration_date}</strong>. You can retain access to the %{plan} features by upgrading below."
+msgid "BillingPlans|Your GitLab.com %{plan} trial will %{strong_open}expire after %{expiration_date}%{strong_close}. You can retain access to the %{plan} features by upgrading below."
msgstr ""
msgid "BillingPlans|Your GitLab.com trial expired on %{expiration_date}. You can restore access to the features at any time by upgrading below."
@@ -5037,7 +5037,7 @@ msgstr ""
msgid "ClusterIntegration|%{title} updated successfully."
msgstr ""
-msgid "ClusterIntegration|A cluster management project can be used to run deployment jobs with Kubernetes <code>cluster-admin</code> privileges."
+msgid "ClusterIntegration|A cluster management project can be used to run deployment jobs with Kubernetes %{code_open}cluster-admin%{code_close} privileges."
msgstr ""
msgid "ClusterIntegration|A service token scoped to %{code}kube-system%{end_code} with %{code}cluster-admin%{end_code} privileges."
@@ -6653,13 +6653,13 @@ msgstr ""
msgid "Contribution Analytics"
msgstr ""
-msgid "ContributionAnalytics|<strong>%{created_count}</strong> created, <strong>%{closed_count}</strong> closed."
+msgid "ContributionAnalytics|%{created_count} created, %{closed_count} closed."
msgstr ""
-msgid "ContributionAnalytics|<strong>%{created_count}</strong> created, <strong>%{merged_count}</strong> merged."
+msgid "ContributionAnalytics|%{created_count} created, %{merged_count} merged."
msgstr ""
-msgid "ContributionAnalytics|<strong>%{pushes}</strong> pushes, more than <strong>%{commits}</strong> commits by <strong>%{people}</strong> contributors."
+msgid "ContributionAnalytics|%{pushes} pushes, more than %{commits} commits by %{people} contributors."
msgstr ""
msgid "ContributionAnalytics|Contribution analytics for issues, merge requests and push events since %{start_date}"
@@ -6689,7 +6689,7 @@ msgstr ""
msgid "ContributionAnalytics|No pushes for the selected time period."
msgstr ""
-msgid "Contributions for <strong>%{calendar_date}</strong>"
+msgid "Contributions for %{calendar_date}"
msgstr ""
msgid "Contributions per group member"
@@ -8887,9 +8887,6 @@ msgstr ""
msgid "Enable Pseudonymizer data collection"
msgstr ""
-msgid "Enable SAML authentication for this group"
-msgstr ""
-
msgid "Enable Seat Link"
msgstr ""
@@ -10456,7 +10453,7 @@ msgstr ""
msgid "Files, directories, and submodules in the path %{path} for commit reference %{ref}"
msgstr ""
-msgid "Fill in the fields below, turn on <strong>%{enable_label}</strong>, and press <strong>%{save_changes}</strong>"
+msgid "Fill in the fields below, turn on %{strong_open}Enable SAML authentication for this group%{strong_close}, and press %{strong_open}Save changes%{strong_close}"
msgstr ""
msgid "Filter"
@@ -10561,7 +10558,7 @@ msgstr ""
msgid "Finish review"
msgstr ""
-msgid "Finish setting up your dedicated account for <strong>%{group_name}</strong>."
+msgid "Finish setting up your dedicated account for %{group_name}."
msgstr ""
msgid "Finished"
@@ -11164,10 +11161,10 @@ msgstr ""
msgid "Geo|Waiting for scheduler"
msgstr ""
-msgid "Geo|You are on a secondary, <b>read-only</b> Geo node. If you want to make changes, you must visit this page on the %{primary_node}."
+msgid "Geo|You are on a secondary, %{b_open}read-only%{b_close} Geo node. If you want to make changes, you must visit this page on the %{node_link_open}primary node%{node_link_close}."
msgstr ""
-msgid "Geo|You are on a secondary, <b>read-only</b> Geo node. You may be able to make a limited amount of changes or perform a limited amount of actions on this page."
+msgid "Geo|You are on a secondary, %{b_open}read-only%{b_close} Geo node. You may be able to make a limited amount of changes or perform a limited amount of actions on this page."
msgstr ""
msgid "Geo|misconfigured"
@@ -12710,10 +12707,10 @@ msgstr ""
msgid "In order to gather accurate feature usage data, it can take 1 to 2 weeks to see your index."
msgstr ""
-msgid "In order to personalize your experience with GitLab<br>we would like to know a bit more about you."
+msgid "In order to personalize your experience with GitLab%{br_tag}we would like to know a bit more about you."
msgstr ""
-msgid "In order to tailor your experience with GitLab we<br>would like to know a bit more about you."
+msgid "In order to tailor your experience with GitLab we%{br_tag}would like to know a bit more about you."
msgstr ""
msgid "In progress"
@@ -17734,7 +17731,7 @@ msgstr ""
msgid "Please provide attributes to update"
msgstr ""
-msgid "Please refer to <a href=\"%{docs_url}\">%{docs_url}</a>"
+msgid "Please refer to %{docs_url}"
msgstr ""
msgid "Please retype the email address."
@@ -20755,7 +20752,7 @@ msgstr ""
msgid "SSH host keys"
msgstr ""
-msgid "SSH host keys are not available on this system. Please use <code>ssh-keyscan</code> command or contact your GitLab administrator for more information."
+msgid "SSH host keys are not available on this system. Please use %{ssh_keyscan} command or contact your GitLab administrator for more information."
msgstr ""
msgid "SSH keys allow you to establish a secure connection between your computer and GitLab."
@@ -21945,7 +21942,7 @@ msgstr ""
msgid "Share"
msgstr ""
-msgid "Share the <strong>%{sso_label}</strong> with members so they can sign in to your group through your identity provider"
+msgid "Share the %{strong_open}GitLab single sign-on URL%{strong_close} with members so they can sign in to your group through your identity provider"
msgstr ""
msgid "Shared Runners"
@@ -22723,7 +22720,7 @@ msgstr ""
msgid "Specify the following URL during the Runner setup:"
msgstr ""
-msgid "Speed up your DevOps<br>with GitLab"
+msgid "Speed up your DevOps%{br_tag}with GitLab"
msgstr ""
msgid "Squash commit message"
@@ -23715,7 +23712,7 @@ msgstr ""
msgid "The CSV export will be created in the background. Once finished, it will be sent to %{strong_open}%{email}%{strong_close} in an attachment."
msgstr ""
-msgid "The Git LFS objects will <strong>not</strong> be synced."
+msgid "The Git LFS objects will %{strong_open}not%{strong_close} be synced."
msgstr ""
msgid "The GitLab user to which the Jira user %{jiraDisplayName} will be mapped"
@@ -24356,7 +24353,7 @@ msgstr ""
msgid "This %{issuableDisplayName} is locked. Only project members can comment."
msgstr ""
-msgid "This %{issuable} is locked. Only <strong>project members</strong> can comment."
+msgid "This %{issuable} is locked. Only %{strong_open}project members%{strong_close} can comment."
msgstr ""
msgid "This %{noteableTypeText} is %{confidentialLinkStart}confidential%{linkEnd} and %{lockedLinkStart}locked%{linkEnd}."
@@ -25590,9 +25587,6 @@ msgstr ""
msgid "U2F only works with HTTPS-enabled websites. Contact your administrator for more details."
msgstr ""
-msgid "UI Development Kit"
-msgstr ""
-
msgid "URL"
msgstr ""
@@ -26010,7 +26004,7 @@ msgstr ""
msgid "Uploads"
msgstr ""
-msgid "Upon performing this action, the contents of this group, its subgroup and projects will be permanently removed after %{deletion_adjourned_period} days on <strong>%{date}</strong>. Until that time:"
+msgid "Upon performing this action, the contents of this group, its subgroup and projects will be permanently removed after %{deletion_adjourned_period} days on %{date}. Until that time:"
msgstr ""
msgid "Upstream"
@@ -26115,7 +26109,7 @@ msgstr ""
msgid "Use %{code_start}::%{code_end} to create a %{link_start}scoped label set%{link_end} (eg. %{code_start}priority::1%{code_end})"
msgstr ""
-msgid "Use <code>%{native_redirect_uri}</code> for local tests"
+msgid "Use %{native_redirect_uri} for local tests"
msgstr ""
msgid "Use Service Desk to connect with your users (e.g. to offer customer support) through email right inside GitLab"
@@ -27013,7 +27007,7 @@ msgstr ""
msgid "Welcome to GitLab, %{first_name}!"
msgstr ""
-msgid "Welcome to GitLab.com<br>@%{name}!"
+msgid "Welcome to GitLab.com%{br_tag}@%{name}!"
msgstr ""
msgid "Welcome to the guided GitLab tour"
@@ -27183,7 +27177,7 @@ msgstr ""
msgid "WikiMarkdownDocs|documentation"
msgstr ""
-msgid "WikiMarkdownTip|To link to a (new) page, simply type <code class=\"js-markup-link-example\">%{link_example}</code>"
+msgid "WikiMarkdownTip|To link to a (new) page, simply type %{link_example}"
msgstr ""
msgid "WikiNewPageTip|Tip: You can specify the full path for the new file. We will automatically create any missing directories."
@@ -27330,7 +27324,7 @@ msgstr ""
msgid "You are about to transfer the control of your account to %{group_name} group. This action is NOT reversible, you won't be able to access any of your groups and projects outside of %{group_name} once this transfer is complete."
msgstr ""
-msgid "You are an admin, which means granting access to <strong>%{client_name}</strong> will allow them to interact with GitLab as an admin as well. Proceed with caution."
+msgid "You are an admin, which means granting access to %{client_name} will allow them to interact with GitLab as an admin as well. Proceed with caution."
msgstr ""
msgid "You are attempting to delete a file that has been previously updated."
@@ -27630,7 +27624,7 @@ msgstr ""
msgid "You left the \"%{membershipable_human_name}\" %{source_type}."
msgstr ""
-msgid "You may also add variables that are made available to the running application by prepending the variable key with <code>K8S_SECRET_</code>."
+msgid "You may also add variables that are made available to the running application by prepending the variable key with %{k8s_secret}."
msgstr ""
msgid "You may close the milestone now."
diff --git a/spec/controllers/help_controller_spec.rb b/spec/controllers/help_controller_spec.rb
index 6c0b3efa53b..3049396dd0f 100644
--- a/spec/controllers/help_controller_spec.rb
+++ b/spec/controllers/help_controller_spec.rb
@@ -159,15 +159,6 @@ RSpec.describe HelpController do
end
end
- describe 'GET #ui' do
- context 'for UI Development Kit' do
- it 'renders found' do
- get :ui
- expect(response).to have_gitlab_http_status(:ok)
- end
- end
- end
-
def stub_readme(content)
expect(File).to receive(:read).and_return(content)
end
diff --git a/spec/features/profiles/user_edit_preferences_spec.rb b/spec/features/profiles/user_edit_preferences_spec.rb
index 817228edca7..d489d92c524 100644
--- a/spec/features/profiles/user_edit_preferences_spec.rb
+++ b/spec/features/profiles/user_edit_preferences_spec.rb
@@ -64,7 +64,7 @@ RSpec.describe 'User edit preferences profile' do
expect(page).to have_select(
'user[preferred_language]',
selected: 'Spanish - español',
- options: Gitlab::I18n::AVAILABLE_LANGUAGES.values,
+ options: Gitlab::I18n.selectable_locales.values,
visible: :all
)
end
diff --git a/spec/features/profiles/user_visits_profile_preferences_page_spec.rb b/spec/features/profiles/user_visits_profile_preferences_page_spec.rb
index 2747b5894dc..56db7efff51 100644
--- a/spec/features/profiles/user_visits_profile_preferences_page_spec.rb
+++ b/spec/features/profiles/user_visits_profile_preferences_page_spec.rb
@@ -76,13 +76,13 @@ RSpec.describe 'User visits the profile preferences page' do
it 'updates their preference' do
wait_for_requests
- select2('eo', from: '#user_preferred_language')
+ select2('pt_BR', from: '#user_preferred_language')
click_button 'Save'
wait_for_requests
refresh
- expect(page).to have_css('html[lang="eo"]')
+ expect(page).to have_css('html[lang="pt-BR"]')
end
end
diff --git a/spec/features/security/project/internal_access_spec.rb b/spec/features/security/project/internal_access_spec.rb
index 99f30d2f904..051bd601c1d 100644
--- a/spec/features/security/project/internal_access_spec.rb
+++ b/spec/features/security/project/internal_access_spec.rb
@@ -479,8 +479,8 @@ RSpec.describe "Internal Project Access" do
it { is_expected.to be_allowed_for(:maintainer).of(project) }
it { is_expected.to be_allowed_for(:developer).of(project) }
it { is_expected.to be_allowed_for(:reporter).of(project) }
- it { is_expected.to be_denied_for(:guest).of(project) }
- it { is_expected.to be_denied_for(:user) }
+ it { is_expected.to be_allowed_for(:guest).of(project) }
+ it { is_expected.to be_allowed_for(:user) }
it { is_expected.to be_denied_for(:external) }
it { is_expected.to be_denied_for(:visitor) }
end
@@ -495,8 +495,8 @@ RSpec.describe "Internal Project Access" do
it { is_expected.to be_allowed_for(:maintainer).of(project) }
it { is_expected.to be_allowed_for(:developer).of(project) }
it { is_expected.to be_allowed_for(:reporter).of(project) }
- it { is_expected.to be_denied_for(:guest).of(project) }
- it { is_expected.to be_denied_for(:user) }
+ it { is_expected.to be_allowed_for(:guest).of(project) }
+ it { is_expected.to be_allowed_for(:user) }
it { is_expected.to be_denied_for(:external) }
it { is_expected.to be_denied_for(:visitor) }
end
@@ -511,8 +511,8 @@ RSpec.describe "Internal Project Access" do
it { is_expected.to be_allowed_for(:maintainer).of(project) }
it { is_expected.to be_allowed_for(:developer).of(project) }
it { is_expected.to be_allowed_for(:reporter).of(project) }
- it { is_expected.to be_denied_for(:guest).of(project) }
- it { is_expected.to be_denied_for(:user) }
+ it { is_expected.to be_allowed_for(:guest).of(project) }
+ it { is_expected.to be_allowed_for(:user) }
it { is_expected.to be_denied_for(:external) }
it { is_expected.to be_denied_for(:visitor) }
end
diff --git a/spec/features/security/project/public_access_spec.rb b/spec/features/security/project/public_access_spec.rb
index ea00a59dee4..75993959f6e 100644
--- a/spec/features/security/project/public_access_spec.rb
+++ b/spec/features/security/project/public_access_spec.rb
@@ -293,10 +293,10 @@ RSpec.describe "Public Project Access" do
it { is_expected.to be_allowed_for(:maintainer).of(project) }
it { is_expected.to be_allowed_for(:developer).of(project) }
it { is_expected.to be_allowed_for(:reporter).of(project) }
- it { is_expected.to be_denied_for(:guest).of(project) }
- it { is_expected.to be_denied_for(:user) }
- it { is_expected.to be_denied_for(:external) }
- it { is_expected.to be_denied_for(:visitor) }
+ it { is_expected.to be_allowed_for(:guest).of(project) }
+ it { is_expected.to be_allowed_for(:user) }
+ it { is_expected.to be_allowed_for(:external) }
+ it { is_expected.to be_allowed_for(:visitor) }
end
describe "GET /:project_path/-/environments/:id" do
@@ -309,10 +309,10 @@ RSpec.describe "Public Project Access" do
it { is_expected.to be_allowed_for(:maintainer).of(project) }
it { is_expected.to be_allowed_for(:developer).of(project) }
it { is_expected.to be_allowed_for(:reporter).of(project) }
- it { is_expected.to be_denied_for(:guest).of(project) }
- it { is_expected.to be_denied_for(:user) }
- it { is_expected.to be_denied_for(:external) }
- it { is_expected.to be_denied_for(:visitor) }
+ it { is_expected.to be_allowed_for(:guest).of(project) }
+ it { is_expected.to be_allowed_for(:user) }
+ it { is_expected.to be_allowed_for(:external) }
+ it { is_expected.to be_allowed_for(:visitor) }
end
describe "GET /:project_path/-/environments/:id/deployments" do
@@ -325,10 +325,10 @@ RSpec.describe "Public Project Access" do
it { is_expected.to be_allowed_for(:maintainer).of(project) }
it { is_expected.to be_allowed_for(:developer).of(project) }
it { is_expected.to be_allowed_for(:reporter).of(project) }
- it { is_expected.to be_denied_for(:guest).of(project) }
- it { is_expected.to be_denied_for(:user) }
- it { is_expected.to be_denied_for(:external) }
- it { is_expected.to be_denied_for(:visitor) }
+ it { is_expected.to be_allowed_for(:guest).of(project) }
+ it { is_expected.to be_allowed_for(:user) }
+ it { is_expected.to be_allowed_for(:external) }
+ it { is_expected.to be_allowed_for(:visitor) }
end
describe "GET /:project_path/-/environments/new" do
diff --git a/spec/finders/merge_requests_finder_spec.rb b/spec/finders/merge_requests_finder_spec.rb
index e3643698012..cc8b04fe80e 100644
--- a/spec/finders/merge_requests_finder_spec.rb
+++ b/spec/finders/merge_requests_finder_spec.rb
@@ -192,43 +192,59 @@ RSpec.describe MergeRequestsFinder do
expect(merge_requests).to contain_exactly(merge_request3)
end
- describe 'WIP state' do
+ describe 'draft state' do
let!(:wip_merge_request1) { create(:merge_request, :simple, author: user, source_project: project5, target_project: project5, title: 'WIP: thing') }
let!(:wip_merge_request2) { create(:merge_request, :simple, author: user, source_project: project6, target_project: project6, title: 'wip thing') }
let!(:wip_merge_request3) { create(:merge_request, :simple, author: user, source_project: project1, target_project: project1, title: '[wip] thing') }
let!(:wip_merge_request4) { create(:merge_request, :simple, author: user, source_project: project1, target_project: project2, title: 'wip: thing') }
+ let!(:draft_merge_request1) { create(:merge_request, :simple, author: user, source_branch: 'draft1', source_project: project5, target_project: project5, title: 'Draft: thing') }
+ let!(:draft_merge_request2) { create(:merge_request, :simple, author: user, source_branch: 'draft2', source_project: project6, target_project: project6, title: '[draft] thing') }
+ let!(:draft_merge_request3) { create(:merge_request, :simple, author: user, source_branch: 'draft3', source_project: project1, target_project: project1, title: '(draft) thing') }
+ let!(:draft_merge_request4) { create(:merge_request, :simple, author: user, source_branch: 'draft4', source_project: project1, target_project: project2, title: 'Draft - thing') }
- it 'filters by wip' do
- params = { wip: 'yes' }
+ [:wip, :draft].each do |draft_param_key|
+ it "filters by #{draft_param_key}" do
+ params = { draft_param_key => 'yes' }
- merge_requests = described_class.new(user, params).execute
+ merge_requests = described_class.new(user, params).execute
- expect(merge_requests).to contain_exactly(merge_request4, merge_request5, wip_merge_request1, wip_merge_request2, wip_merge_request3, wip_merge_request4)
- end
+ expect(merge_requests).to contain_exactly(
+ merge_request4, merge_request5, wip_merge_request1, wip_merge_request2, wip_merge_request3, wip_merge_request4,
+ draft_merge_request1, draft_merge_request2, draft_merge_request3, draft_merge_request4
+ )
+ end
- it 'filters by not wip' do
- params = { wip: 'no' }
+ context 'when merge_request_draft_filter is disabled' do
+ it 'does not include draft merge requests' do
+ stub_feature_flags(merge_request_draft_filter: false)
- merge_requests = described_class.new(user, params).execute
+ merge_requests = described_class.new(user, { draft_param_key => 'yes' }).execute
- expect(merge_requests).to contain_exactly(merge_request1, merge_request2, merge_request3)
- end
+ expect(merge_requests).to contain_exactly(
+ merge_request4, merge_request5, wip_merge_request1, wip_merge_request2, wip_merge_request3, wip_merge_request4
+ )
+ end
+ end
- it 'returns all items if no valid wip param exists' do
- params = { wip: '' }
+ it "filters by not #{draft_param_key}" do
+ params = { draft_param_key => 'no' }
- merge_requests = described_class.new(user, params).execute
+ merge_requests = described_class.new(user, params).execute
- expect(merge_requests).to contain_exactly(
- merge_request1, merge_request2, merge_request3, merge_request4,
- merge_request5, wip_merge_request1, wip_merge_request2, wip_merge_request3,
- wip_merge_request4)
- end
+ expect(merge_requests).to contain_exactly(merge_request1, merge_request2, merge_request3)
+ end
- it 'adds wip to scalar params' do
- scalar_params = described_class.scalar_params
+ it "returns all items if no valid #{draft_param_key} param exists" do
+ params = { draft_param_key => '' }
+
+ merge_requests = described_class.new(user, params).execute
- expect(scalar_params).to include(:wip, :assignee_id)
+ expect(merge_requests).to contain_exactly(
+ merge_request1, merge_request2, merge_request3, merge_request4,
+ merge_request5, wip_merge_request1, wip_merge_request2, wip_merge_request3, wip_merge_request4,
+ draft_merge_request1, draft_merge_request2, draft_merge_request3, draft_merge_request4
+ )
+ end
end
context 'filter by deployment' do
@@ -265,6 +281,14 @@ RSpec.describe MergeRequestsFinder do
end
end
+ describe '.scalar_params' do
+ it 'contains scalar params related to merge requests' do
+ scalar_params = described_class.scalar_params
+
+ expect(scalar_params).to include(:wip, :draft, :assignee_id)
+ end
+ end
+
context 'assignee filtering' do
let(:issuables) { described_class.new(user, params).execute }
diff --git a/spec/frontend/blob/components/__snapshots__/blob_edit_content_spec.js.snap b/spec/frontend/blob/components/__snapshots__/blob_edit_content_spec.js.snap
index 0409b118222..72761c18b3d 100644
--- a/spec/frontend/blob/components/__snapshots__/blob_edit_content_spec.js.snap
+++ b/spec/frontend/blob/components/__snapshots__/blob_edit_content_spec.js.snap
@@ -4,11 +4,15 @@ exports[`Blob Header Editing rendering matches the snapshot 1`] = `
<div
class="file-content code"
>
- <pre
+ <div
data-editor-loading=""
id="editor"
>
- Lorem ipsum dolor sit amet, consectetur adipiscing elit.
- </pre>
+ <pre
+ class="editor-loading-content"
+ >
+ Lorem ipsum dolor sit amet, consectetur adipiscing elit.
+ </pre>
+ </div>
</div>
`;
diff --git a/spec/frontend/environment.js b/spec/frontend/environment.js
index 5622ba17deb..674e89dfef8 100644
--- a/spec/frontend/environment.js
+++ b/spec/frontend/environment.js
@@ -52,6 +52,12 @@ class CustomEnvironment extends JSDOMEnvironment {
// Expose the jsdom (created in super class) to the global so that we can call reconfigure({ url: '' }) to properly set `window.location`
this.global.dom = this.dom;
+
+ Object.assign(this.global.performance, {
+ mark: () => null,
+ measure: () => null,
+ getEntriesByName: () => [],
+ });
}
async teardown() {
diff --git a/spec/lib/gitlab/git/pre_receive_error_spec.rb b/spec/lib/gitlab/git/pre_receive_error_spec.rb
index bf4530c8945..2ad27361c80 100644
--- a/spec/lib/gitlab/git/pre_receive_error_spec.rb
+++ b/spec/lib/gitlab/git/pre_receive_error_spec.rb
@@ -6,15 +6,27 @@ RSpec.describe Gitlab::Git::PreReceiveError do
Gitlab::Git::PreReceiveError::SAFE_MESSAGE_PREFIXES.each do |prefix|
context "error messages prefixed with #{prefix}" do
it 'accepts only errors lines with the prefix' do
- ex = described_class.new("#{prefix} Hello,\nworld!")
+ raw_message = "#{prefix} Hello,\nworld!"
+ ex = described_class.new(raw_message)
expect(ex.message).to eq('Hello,')
+ expect(ex.raw_message).to eq(raw_message)
end
it 'makes its message HTML-friendly' do
- ex = described_class.new("#{prefix} Hello,\n#{prefix} world!\n")
+ raw_message = "#{prefix} Hello,\n#{prefix} world!\n"
+ ex = described_class.new(raw_message)
expect(ex.message).to eq('Hello,<br>world!')
+ expect(ex.raw_message).to eq(raw_message)
+ end
+
+ it 'sanitizes the user message' do
+ raw_message = 'Raw message'
+ ex = described_class.new(raw_message, "#{prefix} User message")
+
+ expect(ex.raw_message).to eq(raw_message)
+ expect(ex.message).to eq('User message')
end
end
end
diff --git a/spec/lib/gitlab/i18n_spec.rb b/spec/lib/gitlab/i18n_spec.rb
index 592adadc362..ee10739195a 100644
--- a/spec/lib/gitlab/i18n_spec.rb
+++ b/spec/lib/gitlab/i18n_spec.rb
@@ -5,6 +5,14 @@ require 'spec_helper'
RSpec.describe Gitlab::I18n do
let(:user) { create(:user, preferred_language: 'es') }
+ describe '.selectable_locales' do
+ it 'does not return languages that should not be available in the UI' do
+ Gitlab::I18n::NOT_AVAILABLE_IN_UI.each do |language|
+ expect(described_class.selectable_locales).not_to include(language)
+ end
+ end
+ end
+
describe '.locale=' do
after do
described_class.use_default_locale
diff --git a/spec/migrations/migrate_incident_issues_to_incident_type_spec.rb b/spec/migrations/migrate_incident_issues_to_incident_type_spec.rb
new file mode 100644
index 00000000000..dc38695c7fe
--- /dev/null
+++ b/spec/migrations/migrate_incident_issues_to_incident_type_spec.rb
@@ -0,0 +1,55 @@
+# frozen_string_literal: true
+
+require 'spec_helper'
+require Rails.root.join('db', 'post_migrate', '20200723040950_migrate_incident_issues_to_incident_type.rb')
+
+RSpec.describe MigrateIncidentIssuesToIncidentType do
+ let(:migration) { described_class.new }
+
+ let(:projects) { table(:projects) }
+ let(:namespaces) { table(:namespaces) }
+ let(:labels) { table(:labels) }
+ let(:issues) { table(:issues) }
+ let(:label_links) { table(:label_links) }
+ let(:label_props) { IncidentManagement::CreateIncidentLabelService::LABEL_PROPERTIES }
+
+ let(:namespace) { namespaces.create!(name: 'foo', path: 'foo') }
+ let!(:project) { projects.create!(namespace_id: namespace.id) }
+ let(:label) { labels.create!(project_id: project.id, **label_props) }
+ let!(:incident_issue) { issues.create!(project_id: project.id) }
+ let!(:other_issue) { issues.create!(project_id: project.id) }
+
+ # Issue issue_type enum
+ let(:issue_type) { 0 }
+ let(:incident_type) { 1 }
+
+ before do
+ label_links.create!(target_id: incident_issue.id, label_id: label.id, target_type: 'Issue')
+ end
+
+ describe '#up' do
+ it 'updates the incident issue type' do
+ expect { migrate! }
+ .to change { incident_issue.reload.issue_type }
+ .from(issue_type)
+ .to(incident_type)
+
+ expect(other_issue.reload.issue_type).to eql(issue_type)
+ end
+ end
+
+ describe '#down' do
+ let!(:incident_issue) { issues.create!(project_id: project.id, issue_type: issue_type) }
+
+ it 'updates the incident issue type' do
+ migration.up
+
+ expect { migration.down }
+ .to change { incident_issue.reload.issue_type }
+ .from(incident_type)
+ .to(issue_type)
+
+ expect(other_issue.reload.issue_type).to eql(issue_type)
+ end
+ end
+end
diff --git a/spec/routing/routing_spec.rb b/spec/routing/routing_spec.rb
index 024d4d467a7..af4becd980b 100644
--- a/spec/routing/routing_spec.rb
+++ b/spec/routing/routing_spec.rb
@@ -115,7 +115,6 @@ end
# help GET /help(.:format) help#index
# help_page GET /help/*path(.:format) help#show
# help_shortcuts GET /help/shortcuts(.:format) help#shortcuts
-# help_ui GET /help/ui(.:format) help#ui
RSpec.describe HelpController, "routing" do
it "to #index" do
expect(get("/help")).to route_to('help#index')
@@ -131,9 +130,6 @@ RSpec.describe HelpController, "routing" do
expect(get(path)).to route_to('help#show',
path: 'workflow/protected_branches/protected_branches1',
format: 'png')
-
- path = '/help/ui'
- expect(get(path)).to route_to('help#ui')
end
end
diff --git a/spec/services/merge_requests/ff_merge_service_spec.rb b/spec/services/merge_requests/ff_merge_service_spec.rb
index c3da02273a4..b4e3516eb9d 100644
--- a/spec/services/merge_requests/ff_merge_service_spec.rb
+++ b/spec/services/merge_requests/ff_merge_service_spec.rb
@@ -113,9 +113,16 @@ RSpec.describe MergeRequests::FfMergeService do
it 'logs and saves error if there is an PreReceiveError exception' do
error_message = 'error message'
+ raw_message = 'The truth is out there'
- allow(service).to receive(:repository).and_raise(Gitlab::Git::PreReceiveError, "GitLab: #{error_message}")
+ pre_receive_error = Gitlab::Git::PreReceiveError.new(raw_message, "GitLab: #{error_message}")
+ allow(service).to receive(:repository).and_raise(pre_receive_error)
allow(service).to receive(:execute_hooks)
+ expect(Gitlab::ErrorTracking).to receive(:track_exception).with(
+ pre_receive_error,
+ pre_receive_message: raw_message,
+ merge_request_id: merge_request.id
+ )
service.execute(merge_request)