Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2021-10-27 12:12:12 +0300
committerGitLab Bot <gitlab-bot@gitlab.com>2021-10-27 12:12:12 +0300
commitef96d56ed3c723ac913ea4d8ab6504043f849555 (patch)
tree018927f4c37e829e16e31894ff8169ee58af59d5
parent784d3f4422c91e83619e3fd26b0e91c4f0e60a94 (diff)
Add latest changes from gitlab-org/gitlab@master
-rw-r--r--.codeclimate.yml40
-rw-r--r--.gitlab/ci/rules.gitlab-ci.yml10
-rw-r--r--GITALY_SERVER_VERSION2
-rw-r--r--app/assets/javascripts/batch_comments/components/draft_note.vue10
-rw-r--r--app/assets/javascripts/notes/components/note_body.vue13
-rw-r--r--app/assets/javascripts/projects/storage_counter/constants.js10
-rw-r--r--doc/integration/jira/jira_server_configuration.md30
-rw-r--r--doc/user/project/repository/mirror/index.md2
-rw-r--r--locale/gitlab.pot17
-rw-r--r--spec/frontend/projects/storage_counter/mock_data.js6
-rw-r--r--spec/tooling/danger/product_intelligence_spec.rb16
-rw-r--r--tooling/danger/product_intelligence.rb8
12 files changed, 93 insertions, 71 deletions
diff --git a/.codeclimate.yml b/.codeclimate.yml
index c479454285e..fe3c6056890 100644
--- a/.codeclimate.yml
+++ b/.codeclimate.yml
@@ -1,5 +1,6 @@
---
-engines:
+version: "2"
+plugins:
bundler-audit:
enabled: true
duplication:
@@ -8,33 +9,22 @@ engines:
languages:
- ruby
- javascript
-ratings:
- paths:
- - Gemfile.lock
- - "**.erb"
- - "**.haml"
- - "**.rb"
- - "**.rhtml"
- - "**.slim"
- - "**.inc"
- - "**.js"
- - "**.jsx"
- - "**.module"
-exclude_paths:
- - config/
- - db/
- - features/
- - node_modules/
- - spec/
- - vendor/
+ rubocop:
+ enabled: false
+exclude_patterns:
+ - "{ee/,jh/,}config/"
+ - "{ee/,jh/,}db/"
+ - "**/log/"
+ - "**/node_modules/"
+ - "**/spec/"
+ - "**/tmp/"
+ - "**/vendor/"
- .yarn-cache/
- - tmp/
+ - backups/
- builds/
- coverage/
+ - file_hooks/
+ - plugins/
- public/
- shared/
- webpack-report/
- - log/
- - backups/
- - plugins/
- - file_hooks/
diff --git a/.gitlab/ci/rules.gitlab-ci.yml b/.gitlab/ci/rules.gitlab-ci.yml
index c3abc716a78..c1bf77a0a6d 100644
--- a/.gitlab/ci/rules.gitlab-ci.yml
+++ b/.gitlab/ci/rules.gitlab-ci.yml
@@ -716,6 +716,7 @@
.rails:rules:decomposed-databases:
rules:
- <<: *if-merge-request-labels-run-decomposed
+ - <<: *if-default-branch-schedule-nightly
.rails:rules:ee-and-foss-migration:
rules:
@@ -1200,12 +1201,16 @@
.rails:rules:detect-previous-failed-tests:
rules:
+ - <<: *if-not-canonical-namespace
+ when: never
- <<: *if-merge-request-labels-run-all-rspec
- <<: *if-merge-request
changes: *code-backstage-patterns
.rails:rules:rerun-previous-failed-tests:
rules:
+ - <<: *if-not-canonical-namespace
+ when: never
- <<: *if-merge-request-labels-run-all-rspec
- <<: *if-merge-request
changes: *code-backstage-patterns
@@ -1507,9 +1512,10 @@
changes: *ci-review-patterns
- <<: *if-dot-com-gitlab-org-merge-request
changes: *frontend-patterns
- allow_failure: true
- <<: *if-dot-com-gitlab-org-merge-request
- changes: *code-qa-patterns
+ changes: *qa-patterns
+ - <<: *if-dot-com-gitlab-org-merge-request
+ changes: *code-patterns
allow_failure: true
- <<: *if-dot-com-ee-schedule-child-pipeline
allow_failure: true
diff --git a/GITALY_SERVER_VERSION b/GITALY_SERVER_VERSION
index 243f3a70c19..0d5366b7e02 100644
--- a/GITALY_SERVER_VERSION
+++ b/GITALY_SERVER_VERSION
@@ -1 +1 @@
-156e65d1de93e779091a0915cf77b2aefa85fadf
+ba8bc12dd0ff83fc726c6c09ee0cb0ebc311a748
diff --git a/app/assets/javascripts/batch_comments/components/draft_note.vue b/app/assets/javascripts/batch_comments/components/draft_note.vue
index f5e3bab6ff0..918519f386b 100644
--- a/app/assets/javascripts/batch_comments/components/draft_note.vue
+++ b/app/assets/javascripts/batch_comments/components/draft_note.vue
@@ -1,5 +1,5 @@
<script>
-import { GlButton } from '@gitlab/ui';
+import { GlButton, GlSafeHtmlDirective } from '@gitlab/ui';
import { mapActions, mapGetters, mapState } from 'vuex';
import NoteableNote from '~/notes/components/noteable_note.vue';
import PublishButton from './publish_button.vue';
@@ -10,6 +10,9 @@ export default {
PublishButton,
GlButton,
},
+ directives: {
+ SafeHtml: GlSafeHtmlDirective,
+ },
props: {
draft: {
type: Object,
@@ -72,6 +75,9 @@ export default {
}
},
},
+ safeHtmlConfig: {
+ ADD_TAGS: ['use', 'gl-emoji'],
+ },
};
</script>
<template>
@@ -104,8 +110,8 @@ export default {
<template v-if="!isEditingDraft">
<div
v-if="draftCommands"
+ v-safe-html:[$options.safeHtmlConfig]="draftCommands"
class="referenced-commands draft-note-commands"
- v-html="draftCommands /* eslint-disable-line vue/no-v-html */"
></div>
<p class="draft-note-actions d-flex">
diff --git a/app/assets/javascripts/notes/components/note_body.vue b/app/assets/javascripts/notes/components/note_body.vue
index 1ce1696e332..c09582d6287 100644
--- a/app/assets/javascripts/notes/components/note_body.vue
+++ b/app/assets/javascripts/notes/components/note_body.vue
@@ -1,5 +1,6 @@
<script>
import $ from 'jquery';
+import { GlSafeHtmlDirective } from '@gitlab/ui';
import { escape } from 'lodash';
import { mapActions, mapGetters, mapState } from 'vuex';
@@ -19,6 +20,9 @@ export default {
noteForm,
Suggestions,
},
+ directives: {
+ SafeHtml: GlSafeHtmlDirective,
+ },
mixins: [autosave],
props: {
note: {
@@ -144,6 +148,9 @@ export default {
this.removeSuggestionInfoFromBatch(suggestionId);
},
},
+ safeHtmlConfig: {
+ ADD_TAGS: ['use', 'gl-emoji'],
+ },
};
</script>
@@ -163,11 +170,7 @@ export default {
@addToBatch="addSuggestionToBatch"
@removeFromBatch="removeSuggestionFromBatch"
/>
- <div
- v-else
- class="note-text md"
- v-html="note.note_html /* eslint-disable-line vue/no-v-html */"
- ></div>
+ <div v-else v-safe-html:[$options.safeHtmlConfig]="note.note_html" class="note-text md"></div>
<note-form
v-if="isEditing"
ref="noteForm"
diff --git a/app/assets/javascripts/projects/storage_counter/constants.js b/app/assets/javascripts/projects/storage_counter/constants.js
index d9b28abfbe7..12d56256b9a 100644
--- a/app/assets/javascripts/projects/storage_counter/constants.js
+++ b/app/assets/javascripts/projects/storage_counter/constants.js
@@ -6,13 +6,13 @@ export const PROJECT_STORAGE_TYPES = [
name: s__('UsageQuota|Artifacts'),
description: s__('UsageQuota|Pipeline artifacts and job artifacts, created with CI/CD.'),
warningMessage: s__(
- 'UsageQuota|There is a known issue with Artifact storage where the total could be incorrect for some projects. More details and progress are available in %{warningLinkStart}the epic%{warningLinkEnd}.',
+ 'UsageQuota|Because of a known issue, the artifact total for some projects may be incorrect. For more details, read %{warningLinkStart}the epic%{warningLinkEnd}.',
),
warningLink: 'https://gitlab.com/groups/gitlab-org/-/epics/5380',
},
{
id: 'lfsObjectsSize',
- name: s__('UsageQuota|LFS Storage'),
+ name: s__('UsageQuota|LFS storage'),
description: s__('UsageQuota|Audio samples, videos, datasets, and graphics.'),
},
{
@@ -23,7 +23,7 @@ export const PROJECT_STORAGE_TYPES = [
{
id: 'repositorySize',
name: s__('UsageQuota|Repository'),
- description: s__('UsageQuota|Git repository, managed by the Gitaly service.'),
+ description: s__('UsageQuota|Git repository.'),
},
{
id: 'snippetsSize',
@@ -55,7 +55,7 @@ export const LEARN_MORE_LABEL = s__('Learn more.');
export const USAGE_QUOTAS_LABEL = s__('UsageQuota|Usage Quotas');
export const HELP_LINK_ARIA_LABEL = s__('UsageQuota|%{linkTitle} help link');
export const TOTAL_USAGE_DEFAULT_TEXT = __('N/A');
-export const TOTAL_USAGE_TITLE = s__('UsageQuota|Usage Breakdown');
+export const TOTAL_USAGE_TITLE = s__('UsageQuota|Usage breakdown');
export const TOTAL_USAGE_SUBTITLE = s__(
- 'UsageQuota|Includes project registry, artifacts, packages, wiki, uploads and other items.',
+ 'UsageQuota|Includes artifacts, repositories, wiki, uploads, and other items.',
);
diff --git a/doc/integration/jira/jira_server_configuration.md b/doc/integration/jira/jira_server_configuration.md
index 32a8cd430f9..63625dd5065 100644
--- a/doc/integration/jira/jira_server_configuration.md
+++ b/doc/integration/jira/jira_server_configuration.md
@@ -17,9 +17,9 @@ credentials, you must:
## Create a Jira Server user
-This process creates a user named `gitlab` and adds it to a new group named `gitlab-developers`:
+This process creates a user named `gitlab`:
-1. Sign in to your Jira instance as an administrator.
+1. Sign in to your Jira instance as a Jira administrator.
1. In the upper right corner of the top menu, go to the gear icon and
select **User Management**.
1. Create a new user account (`gitlab`) with write access to
@@ -37,13 +37,15 @@ After you create the user, create a group for it.
## Create a Jira Server group
-After you [create a Jira Server user](#create-a-jira-server-user), you can create a
-group to assign permissions to the user:
+After you [create a Jira Server user](#create-a-jira-server-user), create a
+group to assign permissions to the user.
-1. Sign in to your Jira instance as an administrator.
+This process adds the `gitlab` user you created to a new group named `gitlab-developers`:
+
+1. Sign in to your Jira instance as a Jira administrator.
1. In the upper right corner of the top menu, go to the gear icon and
select **User Management**.
-1. From the sidebar, select **Groups**.
+1. On the sidebar, select **Groups**.
![Jira create new user](img/jira_create_new_group.png)
@@ -52,12 +54,12 @@ group to assign permissions to the user:
1. To add the `gitlab` user to the `gitlab-developers` group, select **Edit members**.
The `gitlab-developers` group should be listed in the leftmost box as a
selected group.
-1. In the **Add members to selected group(s)** area, enter `gitlab`.
+1. In the **Add members to selected group(s)** section, enter `gitlab`.
1. Select **Add selected users**.
-Jira saves your selection, and `gitlab` should appear in the **Group member(s)**
-area.
+ The `gitlab` user appears in the **Group member(s)**
+ section.
-![Jira added user to group](img/jira_added_user_to_group.png)
+ ![Jira added user to group](img/jira_added_user_to_group.png)
Next, create a permission scheme for your group.
@@ -65,16 +67,16 @@ Next, create a permission scheme for your group.
After creating the group in Jira, grant permissions to the group by creating a permission scheme:
-1. Sign in to your Jira instance as an administrator.
+1. Sign in to your Jira instance as a Jira administrator.
1. In the upper right corner of the top menu, go to the gear icon and
select **Issues**.
-1. From the sidebar, select **Permission Schemes**.
+1. On the sidebar, select **Permission Schemes**.
1. Select **Add Permission Scheme**, enter a **Name** and (optionally) a
**Description**, and then select **Add**.
1. In the permissions scheme list, locate your new permissions scheme, and
select **Permissions**.
-1. Next to **Administer Projects**, select **Edit**. In
- the **Group** list, select `gitlab-developers`.
+1. Next to **Administer Projects**, select **Edit**.
+1. From the **Group** dropdown list, select `gitlab-developers`, and then select **Grant**.
![Jira group access](img/jira_group_access.png)
diff --git a/doc/user/project/repository/mirror/index.md b/doc/user/project/repository/mirror/index.md
index d8f51c0a502..361c0902ebf 100644
--- a/doc/user/project/repository/mirror/index.md
+++ b/doc/user/project/repository/mirror/index.md
@@ -142,7 +142,7 @@ needs this key to establish trust with your GitLab repository. To copy your SSH
1. On the left sidebar, select **Settings > Repository**.
1. Expand **Mirroring repositories**.
1. Scroll to **Mirrored repositories**.
-1. Identify the correct repository, and select **Copy SSH public key**.
+1. Identify the correct repository, and select **Copy SSH public key** (**{copy-to-clipboard}**).
1. Add the public SSH key to the other repository's configuration:
- If the other repository is hosted on GitLab, add the public SSH key
as a [deploy key](../../../project/deploy_keys/index.md).
diff --git a/locale/gitlab.pot b/locale/gitlab.pot
index d58c185e3c6..4a43f510e5e 100644
--- a/locale/gitlab.pot
+++ b/locale/gitlab.pot
@@ -36811,6 +36811,9 @@ msgstr ""
msgid "UsageQuota|Audio samples, videos, datasets, and graphics."
msgstr ""
+msgid "UsageQuota|Because of a known issue, the artifact total for some projects may be incorrect. For more details, read %{warningLinkStart}the epic%{warningLinkEnd}."
+msgstr ""
+
msgid "UsageQuota|Buy additional minutes"
msgstr ""
@@ -36829,10 +36832,10 @@ msgstr ""
msgid "UsageQuota|File attachments and smaller design graphics."
msgstr ""
-msgid "UsageQuota|Git repository, managed by the Gitaly service."
+msgid "UsageQuota|Git repository."
msgstr ""
-msgid "UsageQuota|Includes project registry, artifacts, packages, wiki, uploads and other items."
+msgid "UsageQuota|Includes artifacts, repositories, wiki, uploads, and other items."
msgstr ""
msgid "UsageQuota|Increase storage temporarily"
@@ -36844,6 +36847,9 @@ msgstr ""
msgid "UsageQuota|LFS Storage"
msgstr ""
+msgid "UsageQuota|LFS storage"
+msgstr ""
+
msgid "UsageQuota|Learn more about excess storage usage"
msgstr ""
@@ -36889,9 +36895,6 @@ msgstr ""
msgid "UsageQuota|Storage type"
msgstr ""
-msgid "UsageQuota|There is a known issue with Artifact storage where the total could be incorrect for some projects. More details and progress are available in %{warningLinkStart}the epic%{warningLinkEnd}."
-msgstr ""
-
msgid "UsageQuota|This is the total amount of storage used across your projects within this namespace."
msgstr ""
@@ -36931,10 +36934,10 @@ msgstr ""
msgid "UsageQuota|Usage"
msgstr ""
-msgid "UsageQuota|Usage Breakdown"
+msgid "UsageQuota|Usage Quotas"
msgstr ""
-msgid "UsageQuota|Usage Quotas"
+msgid "UsageQuota|Usage breakdown"
msgstr ""
msgid "UsageQuota|Usage of group resources across the projects in the %{strong_start}%{group_name}%{strong_end} group"
diff --git a/spec/frontend/projects/storage_counter/mock_data.js b/spec/frontend/projects/storage_counter/mock_data.js
index d6630b355c5..6b3e23ac386 100644
--- a/spec/frontend/projects/storage_counter/mock_data.js
+++ b/spec/frontend/projects/storage_counter/mock_data.js
@@ -28,7 +28,7 @@ export const projectData = {
name: 'Artifacts',
description: 'Pipeline artifacts and job artifacts, created with CI/CD.',
warningMessage:
- 'There is a known issue with Artifact storage where the total could be incorrect for some projects. More details and progress are available in %{warningLinkStart}the epic%{warningLinkEnd}.',
+ 'Because of a known issue, the artifact total for some projects may be incorrect. For more details, read %{warningLinkStart}the epic%{warningLinkEnd}.',
helpPath: '/build-artifacts',
},
value: 400000,
@@ -36,7 +36,7 @@ export const projectData = {
{
storageType: {
id: 'lfsObjectsSize',
- name: 'LFS Storage',
+ name: 'LFS storage',
description: 'Audio samples, videos, datasets, and graphics.',
helpPath: '/lsf-objects',
},
@@ -55,7 +55,7 @@ export const projectData = {
storageType: {
id: 'repositorySize',
name: 'Repository',
- description: 'Git repository, managed by the Gitaly service.',
+ description: 'Git repository.',
helpPath: '/repository',
},
value: 3900000,
diff --git a/spec/tooling/danger/product_intelligence_spec.rb b/spec/tooling/danger/product_intelligence_spec.rb
index 3ba4f062856..c090dbb4de4 100644
--- a/spec/tooling/danger/product_intelligence_spec.rb
+++ b/spec/tooling/danger/product_intelligence_spec.rb
@@ -44,20 +44,26 @@ RSpec.describe Tooling::Danger::ProductIntelligence do
context 'with product intelligence label' do
let(:expected_labels) { ['product intelligence::review pending'] }
+ let(:mr_labels) { [] }
before do
allow(fake_helper).to receive(:mr_has_labels?).with('product intelligence').and_return(true)
+ allow(fake_helper).to receive(:mr_labels).and_return(mr_labels)
end
it { is_expected.to match_array(expected_labels) }
- end
- context 'with product intelligence::review pending' do
- before do
- allow(fake_helper).to receive(:mr_has_labels?).and_return(true)
+ context 'with product intelligence::review pending' do
+ let(:mr_labels) { ['product intelligence::review pending'] }
+
+ it { is_expected.to be_empty }
end
- it { is_expected.to be_empty }
+ context 'with product intelligence::approved' do
+ let(:mr_labels) { ['product intelligence::approved'] }
+
+ it { is_expected.to be_empty }
+ end
end
context 'with growth experiment label' do
diff --git a/tooling/danger/product_intelligence.rb b/tooling/danger/product_intelligence.rb
index f56353cae61..72fc8deac43 100644
--- a/tooling/danger/product_intelligence.rb
+++ b/tooling/danger/product_intelligence.rb
@@ -14,10 +14,16 @@ module Tooling
labels = []
labels << 'product intelligence' unless helper.mr_has_labels?('product intelligence')
- labels << 'product intelligence::review pending' unless helper.mr_has_labels?(WORKFLOW_LABELS)
+ labels << 'product intelligence::review pending' unless has_workflow_labels?
labels
end
+
+ private
+
+ def has_workflow_labels?
+ (WORKFLOW_LABELS & helper.mr_labels).any?
+ end
end
end
end