Add latest changes from gitlab-org/gitlab@master
This commit is contained in:
parent
a74cb0526c
commit
acab9fc89c
|
|
@ -1,5 +1,5 @@
|
|||
<script>
|
||||
import { GlLoadingIcon, GlPagination, GlSprintf } from '@gitlab/ui';
|
||||
import { GlLoadingIcon, GlPagination, GlSprintf, GlAlert } from '@gitlab/ui';
|
||||
import { GlBreakpointInstance as bp } from '@gitlab/ui/dist/utils';
|
||||
import Mousetrap from 'mousetrap';
|
||||
import { mapState, mapGetters, mapActions } from 'vuex';
|
||||
|
|
@ -77,6 +77,7 @@ export default {
|
|||
GlPagination,
|
||||
GlSprintf,
|
||||
MrWidgetHowToMergeModal,
|
||||
GlAlert,
|
||||
},
|
||||
alerts: {
|
||||
ALERT_OVERFLOW_HIDDEN,
|
||||
|
|
@ -199,7 +200,6 @@ export default {
|
|||
...mapState('diffs', [
|
||||
'showTreeList',
|
||||
'isLoading',
|
||||
'isBatchLoading',
|
||||
'diffFiles',
|
||||
'diffViewType',
|
||||
'commit',
|
||||
|
|
@ -226,6 +226,8 @@ export default {
|
|||
'isParallelView',
|
||||
'currentDiffIndex',
|
||||
'isVirtualScrollingEnabled',
|
||||
'isBatchLoading',
|
||||
'isBatchLoadingError',
|
||||
]),
|
||||
...mapGetters('batchComments', ['draftsCount']),
|
||||
...mapGetters(['isNotesFetched', 'getNoteableData']),
|
||||
|
|
@ -620,6 +622,9 @@ export default {
|
|||
this.subscribedToVirtualScrollingEvents = true;
|
||||
}
|
||||
},
|
||||
reloadPage() {
|
||||
window.location.reload();
|
||||
},
|
||||
},
|
||||
minTreeWidth: MIN_TREE_WIDTH,
|
||||
maxTreeWidth: MAX_TREE_WIDTH,
|
||||
|
|
@ -638,17 +643,19 @@ export default {
|
|||
:diff-files-count-text="numTotalFiles"
|
||||
/>
|
||||
|
||||
<hidden-files-warning
|
||||
v-if="visibleWarning == $options.alerts.ALERT_OVERFLOW_HIDDEN"
|
||||
:visible="numVisibleFiles"
|
||||
:total="numTotalFiles"
|
||||
:plain-diff-path="plainDiffPath"
|
||||
:email-patch-path="emailPatchPath"
|
||||
/>
|
||||
<collapsed-files-warning
|
||||
v-if="visibleWarning == $options.alerts.ALERT_COLLAPSED_FILES"
|
||||
:limited="isLimitedContainer"
|
||||
/>
|
||||
<template v-if="!isBatchLoadingError">
|
||||
<hidden-files-warning
|
||||
v-if="visibleWarning == $options.alerts.ALERT_OVERFLOW_HIDDEN"
|
||||
:visible="numVisibleFiles"
|
||||
:total="numTotalFiles"
|
||||
:plain-diff-path="plainDiffPath"
|
||||
:email-patch-path="emailPatchPath"
|
||||
/>
|
||||
<collapsed-files-warning
|
||||
v-if="visibleWarning == $options.alerts.ALERT_COLLAPSED_FILES"
|
||||
:limited="isLimitedContainer"
|
||||
/>
|
||||
</template>
|
||||
|
||||
<div
|
||||
:data-can-create-note="getNoteableData.current_user.can_create_note"
|
||||
|
|
@ -677,7 +684,18 @@ export default {
|
|||
}"
|
||||
>
|
||||
<commit-widget v-if="commit" :commit="commit" :collapsible="false" />
|
||||
<div v-if="isBatchLoading" class="loading"><gl-loading-icon size="lg" /></div>
|
||||
<gl-alert
|
||||
v-if="isBatchLoadingError"
|
||||
variant="danger"
|
||||
:dismissible="false"
|
||||
:primary-button-text="__('Reload page')"
|
||||
@primaryAction="reloadPage"
|
||||
>
|
||||
{{ __("Error: Couldn't load some or all of the changes.") }}
|
||||
</gl-alert>
|
||||
<div v-if="isBatchLoading && !isBatchLoadingError" class="loading">
|
||||
<gl-loading-icon size="lg" />
|
||||
</div>
|
||||
<template v-else-if="renderDiffFiles">
|
||||
<dynamic-scroller
|
||||
v-if="isVirtualScrollingEnabled"
|
||||
|
|
@ -753,7 +771,10 @@ export default {
|
|||
</div>
|
||||
<gl-loading-icon v-else-if="retrievingBatches" size="lg" />
|
||||
</template>
|
||||
<no-changes v-else :changes-empty-state-illustration="changesEmptyStateIllustration" />
|
||||
<no-changes
|
||||
v-else-if="!isBatchLoadingError"
|
||||
:changes-empty-state-illustration="changesEmptyStateIllustration"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
<mr-widget-how-to-merge-modal
|
||||
|
|
|
|||
|
|
@ -101,7 +101,7 @@ export const fetchDiffFilesBatch = ({ commit, state, dispatch }) => {
|
|||
let totalLoaded = 0;
|
||||
let scrolledVirtualScroller = false;
|
||||
|
||||
commit(types.SET_BATCH_LOADING, true);
|
||||
commit(types.SET_BATCH_LOADING_STATE, 'loading');
|
||||
commit(types.SET_RETRIEVING_BATCHES, true);
|
||||
eventHub.$emit(EVT_PERF_MARK_DIFF_FILES_START);
|
||||
|
||||
|
|
@ -112,7 +112,7 @@ export const fetchDiffFilesBatch = ({ commit, state, dispatch }) => {
|
|||
totalLoaded += diff_files.length;
|
||||
|
||||
commit(types.SET_DIFF_DATA_BATCH, { diff_files });
|
||||
commit(types.SET_BATCH_LOADING, false);
|
||||
commit(types.SET_BATCH_LOADING_STATE, 'loaded');
|
||||
|
||||
if (window.gon?.features?.diffsVirtualScrolling && !scrolledVirtualScroller) {
|
||||
const index = state.diffFiles.findIndex(
|
||||
|
|
@ -127,7 +127,7 @@ export const fetchDiffFilesBatch = ({ commit, state, dispatch }) => {
|
|||
}
|
||||
|
||||
if (!isNoteLink && !state.currentDiffFileId) {
|
||||
commit(types.VIEW_DIFF_FILE, diff_files[0].file_hash);
|
||||
commit(types.VIEW_DIFF_FILE, diff_files[0]?.file_hash);
|
||||
}
|
||||
|
||||
if (isNoteLink) {
|
||||
|
|
@ -179,11 +179,14 @@ export const fetchDiffFilesBatch = ({ commit, state, dispatch }) => {
|
|||
|
||||
return null;
|
||||
})
|
||||
.catch(() => commit(types.SET_RETRIEVING_BATCHES, false));
|
||||
.catch(() => {
|
||||
commit(types.SET_RETRIEVING_BATCHES, false);
|
||||
commit(types.SET_BATCH_LOADING_STATE, 'error');
|
||||
});
|
||||
|
||||
return getBatch()
|
||||
.then(() => !window.gon?.features?.diffsVirtualScrolling && handleLocationHash())
|
||||
.catch(() => null);
|
||||
return getBatch().then(
|
||||
() => !window.gon?.features?.diffsVirtualScrolling && handleLocationHash(),
|
||||
);
|
||||
};
|
||||
|
||||
export const fetchDiffFilesMeta = ({ commit, state }) => {
|
||||
|
|
|
|||
|
|
@ -191,3 +191,6 @@ export const isVirtualScrollingEnabled = (state) => {
|
|||
getParameterValues('virtual_scrolling')[0] === 'true')
|
||||
);
|
||||
};
|
||||
|
||||
export const isBatchLoading = (state) => state.batchLoadingState === 'loading';
|
||||
export const isBatchLoadingError = (state) => state.batchLoadingState === 'error';
|
||||
|
|
|
|||
|
|
@ -10,7 +10,7 @@ const defaultViewType = INLINE_DIFF_VIEW_TYPE;
|
|||
export default () => ({
|
||||
isLoading: true,
|
||||
isTreeLoaded: false,
|
||||
isBatchLoading: false,
|
||||
batchLoadingState: null,
|
||||
retrievingBatches: false,
|
||||
addedLines: null,
|
||||
removedLines: null,
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
export const SET_BASE_CONFIG = 'SET_BASE_CONFIG';
|
||||
export const SET_LOADING = 'SET_LOADING';
|
||||
export const SET_BATCH_LOADING = 'SET_BATCH_LOADING';
|
||||
export const SET_BATCH_LOADING_STATE = 'SET_BATCH_LOADING_STATE';
|
||||
export const SET_RETRIEVING_BATCHES = 'SET_RETRIEVING_BATCHES';
|
||||
|
||||
export const SET_DIFF_METADATA = 'SET_DIFF_METADATA';
|
||||
|
|
|
|||
|
|
@ -60,8 +60,8 @@ export default {
|
|||
Object.assign(state, { isLoading });
|
||||
},
|
||||
|
||||
[types.SET_BATCH_LOADING](state, isBatchLoading) {
|
||||
Object.assign(state, { isBatchLoading });
|
||||
[types.SET_BATCH_LOADING_STATE](state, batchLoadingState) {
|
||||
Object.assign(state, { batchLoadingState });
|
||||
},
|
||||
|
||||
[types.SET_RETRIEVING_BATCHES](state, retrievingBatches) {
|
||||
|
|
|
|||
|
|
@ -1,12 +0,0 @@
|
|||
import $ from 'jquery';
|
||||
import initDeprecatedJQueryDropdown from '~/deprecated_jquery_dropdown';
|
||||
import { stickyMonitor } from './lib/utils/sticky';
|
||||
|
||||
export default (stickyTop) => {
|
||||
stickyMonitor(document.querySelector('.js-diff-files-changed'), stickyTop);
|
||||
|
||||
initDeprecatedJQueryDropdown($('.js-diff-stats-dropdown'), {
|
||||
filterable: true,
|
||||
remoteFilter: false,
|
||||
});
|
||||
};
|
||||
|
|
@ -0,0 +1,30 @@
|
|||
import Vue from 'vue';
|
||||
import DiffStatsDropdown from '~/vue_shared/components/diff_stats_dropdown.vue';
|
||||
import { stickyMonitor } from './lib/utils/sticky';
|
||||
|
||||
export const initDiffStatsDropdown = (stickyTop) => {
|
||||
if (stickyTop) {
|
||||
stickyMonitor(document.querySelector('.js-diff-files-changed'), stickyTop);
|
||||
}
|
||||
|
||||
const el = document.querySelector('.js-diff-stats-dropdown');
|
||||
|
||||
if (!el) {
|
||||
return false;
|
||||
}
|
||||
|
||||
const { changed, added, deleted, files } = el.dataset;
|
||||
|
||||
return new Vue({
|
||||
el,
|
||||
render: (createElement) =>
|
||||
createElement(DiffStatsDropdown, {
|
||||
props: {
|
||||
changed: parseInt(changed, 10),
|
||||
added: parseInt(added, 10),
|
||||
deleted: parseInt(deleted, 10),
|
||||
files: JSON.parse(files),
|
||||
},
|
||||
}),
|
||||
});
|
||||
};
|
||||
|
|
@ -7,7 +7,7 @@ import createEventHub from '~/helpers/event_hub_factory';
|
|||
import BlobForkSuggestion from './blob/blob_fork_suggestion';
|
||||
import Diff from './diff';
|
||||
import createFlash from './flash';
|
||||
import initChangesDropdown from './init_changes_dropdown';
|
||||
import { initDiffStatsDropdown } from './init_diff_stats_dropdown';
|
||||
import axios from './lib/utils/axios_utils';
|
||||
import {
|
||||
parseUrlPathname,
|
||||
|
|
@ -433,8 +433,7 @@ export default class MergeRequestTabs {
|
|||
.then(({ data }) => {
|
||||
const $container = $('#diffs');
|
||||
$container.html(data.html);
|
||||
|
||||
initChangesDropdown(this.stickyTop);
|
||||
initDiffStatsDropdown(this.stickyTop);
|
||||
|
||||
localTimeAgo(document.querySelectorAll('#diffs .js-timeago'));
|
||||
syntaxHighlight($('#diffs .js-syntax-highlight'));
|
||||
|
|
|
|||
|
|
@ -38,7 +38,7 @@ export default {
|
|||
[types.RECEIVE_PROJECT_MILESTONES_SUCCESS](state, response) {
|
||||
state.matches.projectMilestones = {
|
||||
list: response.data.map(({ title }) => ({ title })),
|
||||
totalCount: parseInt(response.headers['x-total'], 10),
|
||||
totalCount: parseInt(response.headers['x-total'], 10) || response.data.length,
|
||||
error: null,
|
||||
};
|
||||
},
|
||||
|
|
@ -52,7 +52,7 @@ export default {
|
|||
[types.RECEIVE_GROUP_MILESTONES_SUCCESS](state, response) {
|
||||
state.matches.groupMilestones = {
|
||||
list: response.data.map(({ title }) => ({ title })),
|
||||
totalCount: parseInt(response.headers['x-total'], 10),
|
||||
totalCount: parseInt(response.headers['x-total'], 10) || response.data.length,
|
||||
error: null,
|
||||
};
|
||||
},
|
||||
|
|
|
|||
|
|
@ -5,7 +5,9 @@ import {
|
|||
PACKAGE_TYPE_NUGET,
|
||||
PACKAGE_TYPE_CONAN,
|
||||
PACKAGE_TYPE_MAVEN,
|
||||
PACKAGE_TYPE_COMPOSER,
|
||||
} from '~/packages_and_registries/package_registry/constants';
|
||||
import ClipboardButton from '~/vue_shared/components/clipboard_button.vue';
|
||||
import DetailsRow from '~/vue_shared/components/registry/details_row.vue';
|
||||
|
||||
export default {
|
||||
|
|
@ -15,11 +17,17 @@ export default {
|
|||
recipeText: s__('PackageRegistry|Recipe: %{recipe}'),
|
||||
appGroup: s__('PackageRegistry|App group: %{group}'),
|
||||
appName: s__('PackageRegistry|App name: %{name}'),
|
||||
targetShaCopyButton: s__('PackageRegistry|Copy target SHA'),
|
||||
targetSha: s__('PackageRegistry|Target SHA: %{sha}'),
|
||||
composerJson: s__(
|
||||
'PackageRegistry|Composer.json with license: %{license} and version: %{version}',
|
||||
),
|
||||
},
|
||||
components: {
|
||||
DetailsRow,
|
||||
GlLink,
|
||||
GlSprintf,
|
||||
ClipboardButton,
|
||||
},
|
||||
props: {
|
||||
packageEntity: {
|
||||
|
|
@ -30,9 +38,12 @@ export default {
|
|||
computed: {
|
||||
showMetadata() {
|
||||
return (
|
||||
[PACKAGE_TYPE_NUGET, PACKAGE_TYPE_CONAN, PACKAGE_TYPE_MAVEN].includes(
|
||||
this.packageEntity.packageType,
|
||||
) && this.packageEntity.metadata
|
||||
[
|
||||
PACKAGE_TYPE_NUGET,
|
||||
PACKAGE_TYPE_CONAN,
|
||||
PACKAGE_TYPE_MAVEN,
|
||||
PACKAGE_TYPE_COMPOSER,
|
||||
].includes(this.packageEntity.packageType) && this.packageEntity.metadata
|
||||
);
|
||||
},
|
||||
showNugetMetadata() {
|
||||
|
|
@ -44,6 +55,9 @@ export default {
|
|||
showMavenMetadata() {
|
||||
return this.packageEntity.packageType === PACKAGE_TYPE_MAVEN;
|
||||
},
|
||||
showComposerMetadata() {
|
||||
return this.packageEntity.packageType === PACKAGE_TYPE_COMPOSER;
|
||||
},
|
||||
},
|
||||
};
|
||||
</script>
|
||||
|
|
@ -101,6 +115,32 @@ export default {
|
|||
</gl-sprintf>
|
||||
</details-row>
|
||||
</template>
|
||||
|
||||
<template v-else-if="showComposerMetadata">
|
||||
<details-row icon="information-o" padding="gl-p-4" dashed data-testid="composer-target-sha">
|
||||
<gl-sprintf :message="$options.i18n.targetSha">
|
||||
<template #sha>
|
||||
<strong>{{ packageEntity.metadata.targetSha }}</strong>
|
||||
<clipboard-button
|
||||
:title="$options.i18n.targetShaCopyButton"
|
||||
:text="packageEntity.metadata.targetSha"
|
||||
category="tertiary"
|
||||
css-class="gl-p-0!"
|
||||
/>
|
||||
</template>
|
||||
</gl-sprintf>
|
||||
</details-row>
|
||||
<details-row icon="information-o" padding="gl-p-4" data-testid="composer-json">
|
||||
<gl-sprintf :message="$options.i18n.composerJson">
|
||||
<template #license>
|
||||
<strong>{{ packageEntity.metadata.composerJson.license }}</strong>
|
||||
</template>
|
||||
<template #version>
|
||||
<strong>{{ packageEntity.metadata.composerJson.version }}</strong>
|
||||
</template>
|
||||
</gl-sprintf>
|
||||
</details-row>
|
||||
</template>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
|
|
|||
|
|
@ -4,8 +4,8 @@ import loadAwardsHandler from '~/awards_handler';
|
|||
import ShortcutsNavigation from '~/behaviors/shortcuts/shortcuts_navigation';
|
||||
import Diff from '~/diff';
|
||||
import createFlash from '~/flash';
|
||||
import initChangesDropdown from '~/init_changes_dropdown';
|
||||
import initDeprecatedNotes from '~/init_deprecated_notes';
|
||||
import { initDiffStatsDropdown } from '~/init_diff_stats_dropdown';
|
||||
import axios from '~/lib/utils/axios_utils';
|
||||
import { handleLocationHash } from '~/lib/utils/common_utils';
|
||||
import { __ } from '~/locale';
|
||||
|
|
@ -17,7 +17,7 @@ import '~/sourcegraph/load';
|
|||
|
||||
const hasPerfBar = document.querySelector('.with-performance-bar');
|
||||
const performanceHeight = hasPerfBar ? 35 : 0;
|
||||
initChangesDropdown(document.querySelector('.navbar-gitlab').offsetHeight + performanceHeight);
|
||||
initDiffStatsDropdown(document.querySelector('.navbar-gitlab').offsetHeight + performanceHeight);
|
||||
new ZenMode();
|
||||
new ShortcutsNavigation();
|
||||
|
||||
|
|
|
|||
|
|
@ -1,11 +1,11 @@
|
|||
import Diff from '~/diff';
|
||||
import GpgBadges from '~/gpg_badges';
|
||||
import initChangesDropdown from '~/init_changes_dropdown';
|
||||
import { initDiffStatsDropdown } from '~/init_diff_stats_dropdown';
|
||||
import initCompareSelector from '~/projects/compare';
|
||||
|
||||
initCompareSelector();
|
||||
|
||||
new Diff(); // eslint-disable-line no-new
|
||||
const paddingTop = 16;
|
||||
initChangesDropdown(document.querySelector('.navbar-gitlab').offsetHeight - paddingTop);
|
||||
initDiffStatsDropdown(document.querySelector('.navbar-gitlab').offsetHeight - paddingTop);
|
||||
GpgBadges.fetch();
|
||||
|
|
|
|||
|
|
@ -1,3 +1,5 @@
|
|||
import { initDiffStatsDropdown } from '~/init_diff_stats_dropdown';
|
||||
import initWikis from '~/pages/shared/wikis';
|
||||
|
||||
initWikis();
|
||||
initDiffStatsDropdown();
|
||||
|
|
|
|||
|
|
@ -0,0 +1,159 @@
|
|||
<script>
|
||||
import {
|
||||
GlDropdown,
|
||||
GlDropdownItem,
|
||||
GlDropdownText,
|
||||
GlSearchBoxByType,
|
||||
GlSprintf,
|
||||
} from '@gitlab/ui';
|
||||
import fuzzaldrinPlus from 'fuzzaldrin-plus';
|
||||
import { __, n__, s__, sprintf } from '~/locale';
|
||||
|
||||
export const i18n = {
|
||||
messageAdditionsDeletions: s__('Diffs|with %{additions} and %{deletions}'),
|
||||
noFilesFound: __('No files found.'),
|
||||
noFileNameAvailable: s__('Diffs|No file name available'),
|
||||
searchFiles: __('Search files'),
|
||||
};
|
||||
|
||||
export default {
|
||||
i18n,
|
||||
components: {
|
||||
GlDropdown,
|
||||
GlDropdownItem,
|
||||
GlDropdownText,
|
||||
GlSearchBoxByType,
|
||||
GlSprintf,
|
||||
},
|
||||
props: {
|
||||
changed: {
|
||||
type: Number,
|
||||
required: true,
|
||||
},
|
||||
added: {
|
||||
type: Number,
|
||||
required: true,
|
||||
},
|
||||
deleted: {
|
||||
type: Number,
|
||||
required: true,
|
||||
},
|
||||
files: {
|
||||
type: Array,
|
||||
required: true,
|
||||
},
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
search: '',
|
||||
};
|
||||
},
|
||||
computed: {
|
||||
filteredFiles() {
|
||||
return this.search.length > 0
|
||||
? fuzzaldrinPlus.filter(this.files, this.search, { key: 'name' })
|
||||
: this.files;
|
||||
},
|
||||
messageChanged() {
|
||||
return sprintf(
|
||||
n__(
|
||||
'Diffs|Showing %{dropdownStart}%{count} changed file%{dropdownEnd}',
|
||||
'Diffs|Showing %{dropdownStart}%{count} changed files%{dropdownEnd}',
|
||||
this.changed,
|
||||
),
|
||||
{ count: this.changed },
|
||||
);
|
||||
},
|
||||
|
||||
additionsText() {
|
||||
return n__('Diffs|%d addition', 'Diffs|%d additions', this.added);
|
||||
},
|
||||
deletionsText() {
|
||||
return n__('Diffs|%d deletion', 'Diffs|%d deletions', this.deleted);
|
||||
},
|
||||
},
|
||||
methods: {
|
||||
jumpToFile(fileHash) {
|
||||
window.location.hash = fileHash;
|
||||
},
|
||||
focusInput() {
|
||||
this.$refs.search.focusInput();
|
||||
},
|
||||
},
|
||||
};
|
||||
</script>
|
||||
|
||||
<template>
|
||||
<div>
|
||||
<gl-sprintf :message="messageChanged">
|
||||
<template #dropdown="{ content: dropdownText }">
|
||||
<gl-dropdown
|
||||
category="tertiary"
|
||||
variant="confirm"
|
||||
:text="dropdownText"
|
||||
data-testid="diff-stats-dropdown"
|
||||
class="gl-vertical-align-baseline"
|
||||
toggle-class="gl-px-0! gl-font-weight-bold!"
|
||||
menu-class="gl-w-auto!"
|
||||
no-flip
|
||||
@shown="focusInput"
|
||||
>
|
||||
<template #header>
|
||||
<gl-search-box-by-type
|
||||
ref="search"
|
||||
v-model.trim="search"
|
||||
:placeholder="$options.i18n.searchFiles"
|
||||
/>
|
||||
</template>
|
||||
<gl-dropdown-item
|
||||
v-for="file in filteredFiles"
|
||||
:key="file.href"
|
||||
:icon-name="file.icon"
|
||||
:icon-color="file.iconColor"
|
||||
@click="jumpToFile(file.href)"
|
||||
>
|
||||
<div class="gl-display-flex">
|
||||
<span v-if="file.name" class="gl-font-weight-bold gl-mr-3 gl-text-truncate">{{
|
||||
file.name
|
||||
}}</span>
|
||||
<span v-else class="gl-mr-3 gl-font-weight-bold gl-font-style-italic gl-gray-400">{{
|
||||
$options.i18n.noFileNameAvailable
|
||||
}}</span>
|
||||
<span class="gl-ml-auto gl-white-space-nowrap">
|
||||
<span class="gl-text-green-600">+{{ file.added }}</span>
|
||||
<span class="gl-text-red-500">-{{ file.removed }}</span>
|
||||
</span>
|
||||
</div>
|
||||
<div class="gl-text-gray-700 gl-overflow-hidden gl-text-overflow-ellipsis">
|
||||
{{ file.path }}
|
||||
</div>
|
||||
</gl-dropdown-item>
|
||||
<gl-dropdown-text v-if="!filteredFiles.length">
|
||||
{{ $options.i18n.noFilesFound }}
|
||||
</gl-dropdown-text>
|
||||
</gl-dropdown>
|
||||
</template>
|
||||
</gl-sprintf>
|
||||
<span
|
||||
class="diff-stats-additions-deletions-expanded"
|
||||
data-testid="diff-stats-additions-deletions-expanded"
|
||||
>
|
||||
<gl-sprintf :message="$options.i18n.messageAdditionsDeletions">
|
||||
<template #additions>
|
||||
<span class="gl-text-green-600 gl-font-weight-bold">{{ additionsText }}</span>
|
||||
</template>
|
||||
<template #deletions>
|
||||
<span class="gl-text-red-500 gl-font-weight-bold">{{ deletionsText }}</span>
|
||||
</template>
|
||||
</gl-sprintf>
|
||||
</span>
|
||||
|
||||
<div
|
||||
class="diff-stats-additions-deletions-collapsed gl-float-right gl-display-none"
|
||||
data-testid="diff-stats-additions-deletions-collapsed"
|
||||
>
|
||||
<span class="gl-text-green-600 gl-font-weight-bold">+{{ added }}</span>
|
||||
<span class="gl-text-red-500 gl-font-weight-bold">-{{ deleted }}</span>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
|
@ -682,26 +682,6 @@ table.code {
|
|||
max-height: 50vh;
|
||||
}
|
||||
|
||||
.diff-stats-summary-toggler {
|
||||
padding: 0;
|
||||
background-color: transparent;
|
||||
border: 0;
|
||||
color: $blue-600;
|
||||
font-weight: $gl-font-weight-bold;
|
||||
|
||||
&:hover,
|
||||
&:focus {
|
||||
outline: none;
|
||||
color: $blue-800;
|
||||
}
|
||||
|
||||
.caret-icon {
|
||||
position: relative;
|
||||
top: 2px;
|
||||
left: -1px;
|
||||
}
|
||||
}
|
||||
|
||||
// Mobile
|
||||
@media (max-width: 480px) {
|
||||
.diff-title {
|
||||
|
|
@ -853,21 +833,14 @@ table.code {
|
|||
|
||||
.diff-files-changed {
|
||||
.inline-parallel-buttons {
|
||||
position: relative;
|
||||
@include gl-relative;
|
||||
z-index: 1;
|
||||
}
|
||||
|
||||
.commit-stat-summary {
|
||||
@include media-breakpoint-up(sm) {
|
||||
background-color: $white;
|
||||
}
|
||||
}
|
||||
|
||||
@include media-breakpoint-up(sm) {
|
||||
position: -webkit-sticky;
|
||||
position: sticky;
|
||||
@include gl-sticky;
|
||||
top: $header-height + $mr-tabs-height;
|
||||
background-color: $white;
|
||||
@include gl-bg-white;
|
||||
z-index: 200;
|
||||
|
||||
.with-performance-bar & {
|
||||
|
|
@ -875,14 +848,13 @@ table.code {
|
|||
}
|
||||
|
||||
&.is-stuck {
|
||||
padding-top: 0;
|
||||
padding-bottom: 0;
|
||||
@include gl-py-0;
|
||||
border-top: 1px solid $white-dark;
|
||||
border-bottom: 1px solid $white-dark;
|
||||
|
||||
.diff-stats-additions-deletions-expanded,
|
||||
.inline-parallel-buttons {
|
||||
display: none !important;
|
||||
@include gl-display-none;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -890,12 +862,13 @@ table.code {
|
|||
@include media-breakpoint-up(lg) {
|
||||
&.is-stuck {
|
||||
.diff-stats-additions-deletions-collapsed {
|
||||
display: block !important;
|
||||
@include gl-display-block;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
.diff-file-changes {
|
||||
max-width: 560px;
|
||||
width: 100%;
|
||||
|
|
|
|||
|
|
@ -39,36 +39,6 @@
|
|||
}
|
||||
}
|
||||
|
||||
.signup-page[data-page^='registrations:experience_levels'] {
|
||||
$card-shadow-color: rgba(var(--black, $black), 0.2);
|
||||
|
||||
.page-wrap {
|
||||
background-color: var(--white, $white);
|
||||
}
|
||||
|
||||
.card-deck {
|
||||
max-width: 828px;
|
||||
}
|
||||
|
||||
.card {
|
||||
transition: box-shadow 0.3s ease-in-out;
|
||||
}
|
||||
|
||||
.card:hover {
|
||||
box-shadow: 0 $gl-spacing-scale-3 $gl-spacing-scale-5 $card-shadow-color;
|
||||
}
|
||||
|
||||
@media (min-width: $breakpoint-sm) {
|
||||
.card-deck .card {
|
||||
margin: 0 $gl-spacing-scale-3;
|
||||
}
|
||||
}
|
||||
|
||||
.stretched-link:hover {
|
||||
text-decoration: none;
|
||||
}
|
||||
}
|
||||
|
||||
.edit-profile {
|
||||
max-width: 460px;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,44 +0,0 @@
|
|||
# frozen_string_literal: true
|
||||
|
||||
module Registrations
|
||||
class ExperienceLevelsController < ApplicationController
|
||||
layout 'minimal'
|
||||
|
||||
before_action :ensure_namespace_path_param
|
||||
|
||||
feature_category :onboarding
|
||||
|
||||
def update
|
||||
current_user.experience_level = params[:experience_level]
|
||||
|
||||
if current_user.save
|
||||
hide_advanced_issues
|
||||
|
||||
if learn_gitlab.available?
|
||||
redirect_to namespace_project_board_path(params[:namespace_path], learn_gitlab.project, learn_gitlab.board)
|
||||
else
|
||||
redirect_to group_path(params[:namespace_path])
|
||||
end
|
||||
else
|
||||
render :show
|
||||
end
|
||||
end
|
||||
|
||||
private
|
||||
|
||||
def ensure_namespace_path_param
|
||||
redirect_to root_path unless params[:namespace_path].present?
|
||||
end
|
||||
|
||||
def hide_advanced_issues
|
||||
return unless current_user.user_preference.novice?
|
||||
return unless learn_gitlab.available?
|
||||
|
||||
Boards::UpdateService.new(learn_gitlab.project, current_user, label_ids: [learn_gitlab.label.id]).execute(learn_gitlab.board)
|
||||
end
|
||||
|
||||
def learn_gitlab
|
||||
@learn_gitlab ||= LearnGitlab::Project.new(current_user)
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
@ -183,9 +183,9 @@ module DiffHelper
|
|||
|
||||
def diff_file_changed_icon_color(diff_file)
|
||||
if diff_file.deleted_file?
|
||||
"cred"
|
||||
"danger"
|
||||
elsif diff_file.new_file?
|
||||
"cgreen"
|
||||
"success"
|
||||
end
|
||||
end
|
||||
|
||||
|
|
@ -248,6 +248,23 @@ module DiffHelper
|
|||
toggle_whitespace_link(url, options)
|
||||
end
|
||||
|
||||
def diff_files_data(diff_files)
|
||||
diffs_map = diff_files.map do |f|
|
||||
{
|
||||
href: "##{hexdigest(f.file_path)}",
|
||||
title: f.new_path,
|
||||
name: f.file_path,
|
||||
path: diff_file_path_text(f),
|
||||
icon: diff_file_changed_icon(f),
|
||||
iconColor: "#{diff_file_changed_icon_color(f)}",
|
||||
added: f.added_lines,
|
||||
removed: f.removed_lines
|
||||
}
|
||||
end
|
||||
|
||||
diffs_map.to_json
|
||||
end
|
||||
|
||||
def hide_whitespace?
|
||||
params[:w] == '1'
|
||||
end
|
||||
|
|
|
|||
|
|
@ -307,7 +307,6 @@ class User < ApplicationRecord
|
|||
:gitpod_enabled, :gitpod_enabled=,
|
||||
:setup_for_company, :setup_for_company=,
|
||||
:render_whitespace_in_code, :render_whitespace_in_code=,
|
||||
:experience_level, :experience_level=,
|
||||
:markdown_surround_selection, :markdown_surround_selection=,
|
||||
to: :user_preference
|
||||
|
||||
|
|
|
|||
|
|
@ -20,7 +20,7 @@ class UserPreference < ApplicationRecord
|
|||
less_than_or_equal_to: Gitlab::TabWidth::MAX
|
||||
}
|
||||
|
||||
enum experience_level: { novice: 0, experienced: 1 }
|
||||
ignore_columns :experience_level, remove_with: '14.10', remove_after: '2021-03-22'
|
||||
|
||||
default_value_for :tab_width, value: Gitlab::TabWidth::DEFAULT, allows_nil: false
|
||||
default_value_for :timezone, value: Time.zone.tzinfo.name, allows_nil: false
|
||||
|
|
|
|||
|
|
@ -1,41 +1 @@
|
|||
- sum_added_lines = diff_files.sum(&:added_lines)
|
||||
- sum_removed_lines = diff_files.sum(&:removed_lines)
|
||||
.commit-stat-summary.dropdown
|
||||
Showing
|
||||
%button.diff-stats-summary-toggler.js-diff-stats-dropdown{ type: "button", data: { toggle: "dropdown", display: "static" } }<
|
||||
= pluralize(diff_files.size, "changed file")
|
||||
= sprite_icon("chevron-down", css_class: "gl-ml-2")
|
||||
%span.diff-stats-additions-deletions-expanded#diff-stats
|
||||
with
|
||||
%strong.cgreen= pluralize(sum_added_lines, 'addition')
|
||||
and
|
||||
%strong.cred= pluralize(sum_removed_lines, 'deletion')
|
||||
.diff-stats-additions-deletions-collapsed.float-right.d-none{ "aria-hidden": "true", "aria-describedby": "diff-stats" }
|
||||
%strong.cgreen<
|
||||
+#{sum_added_lines}
|
||||
%strong.cred<
|
||||
\-#{sum_removed_lines}
|
||||
.dropdown-menu.diff-file-changes
|
||||
= dropdown_filter("Search files")
|
||||
.dropdown-content
|
||||
%ul
|
||||
- diff_files.each do |diff_file|
|
||||
%li
|
||||
%a.diff-changed-file{ href: "##{hexdigest(diff_file.file_path)}", title: diff_file.new_path }
|
||||
= sprite_icon(diff_file_changed_icon(diff_file), css_class: "#{diff_file_changed_icon_color(diff_file)} diff-file-changed-icon gl-mr-3")
|
||||
%span.diff-changed-file-content.gl-mr-3
|
||||
- if diff_file.file_path
|
||||
%strong.diff-changed-file-name
|
||||
= diff_file.file_path
|
||||
- else
|
||||
%strong.diff-changed-blank-file-name
|
||||
= s_('Diffs|No file name available')
|
||||
%span.diff-changed-file-path.gl-mt-2= diff_file_path_text(diff_file)
|
||||
%span.diff-changed-stats
|
||||
%span.cgreen<
|
||||
+#{diff_file.added_lines}
|
||||
%span.cred<
|
||||
\-#{diff_file.removed_lines}
|
||||
%li.dropdown-menu-empty-item.hidden
|
||||
%a
|
||||
= _("No files found.")
|
||||
.js-diff-stats-dropdown{ data: { changed: diff_files.size, added: diff_files.sum(&:added_lines), deleted: diff_files.sum(&:removed_lines), files: diff_files_data(diff_files) } }
|
||||
|
|
|
|||
|
|
@ -1,29 +0,0 @@
|
|||
- page_title _('What’s your experience level?')
|
||||
- @hide_flash = true
|
||||
|
||||
.gl-display-flex.gl-flex-direction-column.gl-align-items-center
|
||||
= image_tag 'learn-gitlab-avatar.jpg', width: '90'
|
||||
|
||||
%h2.gl-text-center.gl-mt-3.gl-mb-3= _('Hello there')
|
||||
%p.gl-text-center.gl-font-lg.gl-mb-6= _('Welcome to the guided GitLab tour')
|
||||
|
||||
%h3.gl-text-center.gl-font-lg.gl-mt-6.gl-mb-0= _('What describes you best?')
|
||||
|
||||
.card-deck.gl-mt-6
|
||||
.card
|
||||
.card-body.gl-display-flex.gl-py-8.gl-pr-5.gl-pl-7
|
||||
.gl-align-self-center.gl-pr-6
|
||||
= image_tag 'novice.svg', width: '78', height: '78', alt: ''
|
||||
%div
|
||||
%p.gl-font-lg.gl-font-weight-bold.gl-mb-2= _('Novice')
|
||||
%p= _('I’m not familiar with the basics of DevOps.')
|
||||
= link_to _('Show me the basics'), users_sign_up_experience_level_path(experience_level: :novice, namespace_path: params[:namespace_path]), method: :patch, class: 'stretched-link'
|
||||
|
||||
.card
|
||||
.card-body.gl-display-flex.gl-py-8.gl-pr-5.gl-pl-7
|
||||
.gl-align-self-center.gl-pr-6
|
||||
= image_tag 'experienced.svg', width: '78', height: '78', alt: ''
|
||||
%div
|
||||
%p.gl-font-lg.gl-font-weight-bold.gl-mb-2= _('Experienced')
|
||||
%p= _('I’m familiar with the basics of DevOps.')
|
||||
= link_to _('Show me advanced features'), users_sign_up_experience_level_path(experience_level: :experienced, namespace_path: params[:namespace_path]), method: :patch, class: 'stretched-link'
|
||||
|
|
@ -0,0 +1,8 @@
|
|||
---
|
||||
name: lower_relation_max_count_limit
|
||||
introduced_by_url: https://gitlab.com/gitlab-org/gitlab/-/merge_requests/69620
|
||||
rollout_issue_url:
|
||||
milestone: '14.3'
|
||||
type: ops
|
||||
group: group::verify
|
||||
default_enabled: false
|
||||
|
|
@ -4,6 +4,7 @@ module Kaminari
|
|||
# Active Record specific page scope methods implementations
|
||||
module ActiveRecordRelationMethodsWithLimit
|
||||
MAX_COUNT_LIMIT = 10_000
|
||||
MAX_COUNT_NEW_LOWER_LIMIT = 1_000
|
||||
|
||||
# This is a modified version of
|
||||
# https://github.com/kaminari/kaminari/blob/c5186f5d9b7f23299d115408e62047447fd3189d/kaminari-activerecord/lib/kaminari/activerecord/active_record_relation_methods.rb#L17-L41
|
||||
|
|
@ -21,7 +22,8 @@ module Kaminari
|
|||
return @total_count = (current_page - 1) * limit_value + @records.length if @records.any? && (@records.length < limit_value)
|
||||
end
|
||||
|
||||
limit = options.fetch(:limit, MAX_COUNT_LIMIT).to_i
|
||||
max_limit = Feature.enabled?(:lower_relation_max_count_limit, type: :ops) ? MAX_COUNT_NEW_LOWER_LIMIT : MAX_COUNT_LIMIT
|
||||
limit = options.fetch(:limit, max_limit).to_i
|
||||
# #count overrides the #select which could include generated columns referenced in #order, so skip #order here, where it's irrelevant to the result anyway
|
||||
c = except(:offset, :limit, :order)
|
||||
# Remove includes only if they are irrelevant
|
||||
|
|
|
|||
|
|
@ -63,8 +63,6 @@ Rails.application.routes.draw do
|
|||
end
|
||||
end
|
||||
|
||||
resource :experience_level, only: [:show, :update]
|
||||
|
||||
Gitlab.ee do
|
||||
resources :groups, only: [:new, :create]
|
||||
resources :projects, only: [:new, :create]
|
||||
|
|
|
|||
|
|
@ -16,7 +16,7 @@ To enable the Atlassian OmniAuth provider for passwordless authentication you mu
|
|||
1. Click **Create a new app**.
|
||||
1. Choose an App Name, such as 'GitLab', and click **Create**.
|
||||
1. Note the `Client ID` and `Secret` for the [GitLab configuration](#gitlab-configuration) steps.
|
||||
1. In the left sidebar under **APIS AND FEATURES**, click **OAuth 2.0 (3LO)**.
|
||||
1. On the left sidebar under **APIS AND FEATURES**, click **OAuth 2.0 (3LO)**.
|
||||
1. Enter the GitLab callback URL using the format `https://gitlab.example.com/users/auth/atlassian_oauth2/callback` and click **Save changes**.
|
||||
1. Click **+ Add** in the left sidebar under **APIS AND FEATURES**.
|
||||
1. Click **Add** for **Jira platform REST API** and then **Configure**.
|
||||
|
|
|
|||
|
|
@ -129,3 +129,25 @@ or the path to `config.yaml` inside the project is not valid.
|
|||
|
||||
To fix this, ensure that the paths to the configuration repository and to the `config.yaml` file
|
||||
are correct.
|
||||
|
||||
### KAS logs - dial tcp <GITLAB_INTERNAL_IP>:443: connect: connection refused
|
||||
|
||||
If you are running a self-managed GitLab instance and:
|
||||
|
||||
- The instance isn't running behind an SSL-terminating proxy.
|
||||
- The instance doesn't have HTTPS configured on the GitLab instance itself.
|
||||
- The instance's hostname resolves locally to its internal IP address.
|
||||
|
||||
You may see the following error when the KAS tries to connect to the GitLab API:
|
||||
|
||||
```json
|
||||
{"level":"error","time":"2021-08-16T14:56:47.289Z","msg":"GetAgentInfo()","correlation_id":"01FD7QE35RXXXX8R47WZFBAXTN","grpc_service":"gitlab.agent.reverse_tunnel.rpc.ReverseTunnel","grpc_method":"Connect","error":"Get \"https://gitlab.example.com/api/v4/internal/kubernetes/agent_info\": dial tcp 172.17.0.4:443: connect: connection refused"}
|
||||
```
|
||||
|
||||
To fix this for [Omnibus](https://docs.gitlab.com/omnibus/) package installations,
|
||||
set the following parameter in `/etc/gitlab/gitlab.rb`
|
||||
(replacing `gitlab.example.com` with your GitLab instance's hostname):
|
||||
|
||||
```ruby
|
||||
gitlab_kas['gitlab_address'] = 'http://gitlab.example.com'
|
||||
```
|
||||
|
|
|
|||
|
|
@ -33,7 +33,7 @@ you're ready to enable the Mailgun integration:
|
|||
|
||||
1. Sign in to GitLab as an [Administrator](../../user/permissions.md) user.
|
||||
1. On the top bar, select **Menu >** **{admin}** **Admin**.
|
||||
1. In the left sidebar, go to **Settings > General** and expand the **Mailgun** section.
|
||||
1. On the left sidebar, go to **Settings > General** and expand the **Mailgun** section.
|
||||
1. Select the **Enable Mailgun** check box.
|
||||
1. Enter the Mailgun HTTP webhook signing key as described in
|
||||
[the Mailgun documentation](https://documentation.mailgun.com/en/latest/user_manual.html#webhooks) and
|
||||
|
|
|
|||
|
|
@ -207,7 +207,7 @@ After configuring your local PlantUML server, you're ready to enable the PlantUM
|
|||
|
||||
1. Sign in to GitLab as an [Administrator](../../user/permissions.md) user.
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, go to **Settings > General** and expand the **PlantUML** section.
|
||||
1. On the left sidebar, go to **Settings > General** and expand the **PlantUML** section.
|
||||
1. Select the **Enable PlantUML** checkbox.
|
||||
1. Set the PlantUML instance as `https://gitlab.example.com/-/plantuml/`,
|
||||
and click **Save changes**.
|
||||
|
|
|
|||
|
|
@ -36,6 +36,14 @@ For more details about the Puma configuration, see the
|
|||
|
||||
## Puma Worker Killer
|
||||
|
||||
Puma forks worker processes as part of a strategy to reduce memory use.
|
||||
|
||||
Each time a worker is created, it shares memory with the primary process and
|
||||
only uses additional memory when it makes changes or additions to its memory pages.
|
||||
|
||||
Memory use by workers therefore increases over time, and Puma Worker Killer is the
|
||||
mechanism that recovers this memory.
|
||||
|
||||
By default:
|
||||
|
||||
- The [Puma Worker Killer](https://github.com/schneems/puma_worker_killer) restarts a worker if it
|
||||
|
|
@ -56,6 +64,47 @@ To change the memory limit setting:
|
|||
sudo gitlab-ctl reconfigure
|
||||
```
|
||||
|
||||
There are costs associated with killing and replacing workers including
|
||||
reduced capacity to run GitLab, and CPU that is consumed
|
||||
restarting the workers. `per_worker_max_memory_mb` should be set to a
|
||||
higher value if the worker killer is replacing workers too often.
|
||||
|
||||
Worker count is calculated based on CPU cores, so a small GitLab deployment
|
||||
wih 4-8 workers may experience performance issues if workers are being restarted
|
||||
frequently, once or more per minute. This is too often.
|
||||
|
||||
A higher value of `1200` or more would be beneficial if the server has free memory.
|
||||
|
||||
The worker killer checks every 20 seconds, and can be monitored using
|
||||
[the Puma log](../logs.md#puma_stdoutlog) `/var/log/gitlab/puma/puma_stdout.log`.
|
||||
For example, for GitLab 13.5:
|
||||
|
||||
```plaintext
|
||||
PumaWorkerKiller: Out of memory. 4 workers consuming total: 4871.23828125 MB
|
||||
out of max: 4798.08 MB. Sending TERM to pid 26668 consuming 1001.00390625 MB.
|
||||
```
|
||||
|
||||
From this output:
|
||||
|
||||
- The formula that calculates the maximum memory value results in workers
|
||||
being killed before they reach the `per_worker_max_memory_mb` value.
|
||||
- The default values for the formula before GitLab 13.5 were 550MB for the primary
|
||||
and `per_worker_max_memory_mb` specified 850MB for each worker.
|
||||
- As of GitLab 13.5 the values are primary: 800MB, worker: 1024MB.
|
||||
- The threshold for workers to be killed is set at 98% of the limit:
|
||||
|
||||
```plaintext
|
||||
0.98 * ( 800 + ( worker_processes * 1024MB ) )
|
||||
```
|
||||
|
||||
- In the log output above, `0.98 * ( 800 + ( 4 * 1024 ) )` returns the
|
||||
`max: 4798.08 MB` value.
|
||||
|
||||
Increasing the maximum to `1200`, for example, would set a `max: 5488 MB` value.
|
||||
|
||||
Workers use additional memory on top of the shared memory, how much
|
||||
depends on a site's use of GitLab.
|
||||
|
||||
## Worker timeout
|
||||
|
||||
A [timeout of 60 seconds](https://gitlab.com/gitlab-org/gitlab/-/blob/master/config/initializers/rack_timeout.rb)
|
||||
|
|
@ -95,7 +144,6 @@ considered as a fair tradeoff in a memory-constraint environment.
|
|||
|
||||
When running Puma in Single mode, some features are not supported:
|
||||
|
||||
- Phased restart do not work: [issue](https://gitlab.com/gitlab-org/gitlab/-/issues/300665)
|
||||
- [Phased restart](https://gitlab.com/gitlab-org/gitlab/-/issues/300665)
|
||||
- [Puma Worker Killer](https://gitlab.com/gitlab-org/gitlab/-/issues/300664)
|
||||
|
||||
|
|
|
|||
|
|
@ -17,7 +17,7 @@ storage such as a content delivery network (CDN).
|
|||
To configure external storage for static objects:
|
||||
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **Settings > Repository**.
|
||||
1. On the left sidebar, select **Settings > Repository**.
|
||||
1. Expand the **External storage for repository static objects** section.
|
||||
1. Enter the base URL and an arbitrary token. When you [set up external storage](#set-up-external-storage),
|
||||
use a script that sets these values as `ORIGIN_HOSTNAME` and `STORAGE_TOKEN`.
|
||||
|
|
|
|||
|
|
@ -77,9 +77,9 @@ Use lowercase for **boards**, **issue boards**, and **epic boards**.
|
|||
|
||||
## box
|
||||
|
||||
Use instead of **field** or **text box**. For example:
|
||||
Use **text box** to refer to the UI field. Do not use **field** or **box**. For example:
|
||||
|
||||
- In the **Variable name** box, enter `my text`.
|
||||
- In the **Variable name** text box, enter `my text`.
|
||||
|
||||
## button
|
||||
|
||||
|
|
@ -93,6 +93,15 @@ Don't use a descriptor.
|
|||
One word, **checkbox**. Do not use **check box**.
|
||||
|
||||
You **select** (not **check** or **enable**) and **clear** (not **deselect** or **disable**) checkboxes.
|
||||
For example:
|
||||
|
||||
- Select the **Protect environment** checkbox.
|
||||
- Clear the **Protect environment** checkbox.
|
||||
|
||||
If you must refer to the checkbox, you can say it is selected or cleared. For example:
|
||||
|
||||
- Ensure the **Protect environment** checkbox is cleared.
|
||||
- Ensure the **Protect environment** checkbox is selected.
|
||||
|
||||
## CI/CD
|
||||
|
||||
|
|
@ -519,6 +528,10 @@ Lowercase. For example:
|
|||
- Open a terminal.
|
||||
- From a terminal, run the `docker login` command.
|
||||
|
||||
## text box
|
||||
|
||||
Use instead of **field** or **box** when referring to the UI element.
|
||||
|
||||
## there is, there are
|
||||
|
||||
Try to avoid. These phrases hide the subject.
|
||||
|
|
|
|||
|
|
@ -25,7 +25,7 @@ GitLab does not allow requests to localhost or the local network by default. Whe
|
|||
|
||||
1. Log into your GitLab instance as an administrator.
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **Settings > Network**.
|
||||
1. On the left sidebar, select **Settings > Network**.
|
||||
1. Expand **Outbound requests** and check the following checkboxes:
|
||||
|
||||
- **Allow requests to the local network from web hooks and services**
|
||||
|
|
|
|||
|
|
@ -4,7 +4,10 @@ group: Project Management
|
|||
info: To determine the technical writer assigned to the Stage/Group associated with this page, see https://about.gitlab.com/handbook/engineering/ux/technical-writing/#assignments
|
||||
---
|
||||
|
||||
# Issue Types
|
||||
# Issue Types (DEPRECATED)
|
||||
|
||||
WARNING:
|
||||
We are deprecating Issue Types as of GitLab 14.2 in favor of [Work Items and Work Item Types](work_items.md).
|
||||
|
||||
Sometimes when a new resource type is added it's not clear if it should be only an
|
||||
"extension" of Issue (Issue Type) or if it should be a new first-class resource type
|
||||
|
|
|
|||
|
|
@ -0,0 +1,196 @@
|
|||
---
|
||||
stage: Plan
|
||||
group: Project Management
|
||||
info: To determine the technical writer assigned to the Stage/Group associated with this page, see https://about.gitlab.com/handbook/engineering/ux/technical-writing/#assignments
|
||||
---
|
||||
# Work items and work item types
|
||||
|
||||
## Challenges
|
||||
|
||||
Issues have the potential to be a centralized hub for collaboration.
|
||||
We need to accept the
|
||||
fact that different issue types require different fields and different context, depending
|
||||
on what job they are being used to accomplish. For example:
|
||||
|
||||
- A bug needs to list steps to reproduce.
|
||||
- An incident needs references to stack traces and other contextual information relevant only
|
||||
to that incident.
|
||||
|
||||
Instead of each object type diverging into a separate model, we can standardize on an underlying
|
||||
common model that we can customize with the widgets (one or more attributes) it contains.
|
||||
|
||||
Here are some problems with current issues usage and why we are looking into work items:
|
||||
|
||||
- Using labels to show issue types is cumbersome and makes reporting views more complex.
|
||||
- Issue types are one of the top two use cases of labels, so it makes sense to provide first class
|
||||
support for them.
|
||||
- Issues are starting to become cluttered as we add more capabilities to them, and they are not
|
||||
perfect:
|
||||
|
||||
- There is no consistent pattern for how to surface relationships to other objects.
|
||||
- There is not a coherent interaction model across different types of issues because we use
|
||||
labels for this.
|
||||
- The various implementations of issue types lack flexibility and extensibility.
|
||||
|
||||
- Epics, issues, requirements, and others all have similar but just subtle enough
|
||||
differences in common interactions that the user needs to hold a complicated mental
|
||||
model of how they each behave.
|
||||
- Issues are not extensible enough to support all of the emerging jobs they need to facilitate.
|
||||
- Codebase maintainability and feature development become bigger challenges as we grow the Issue type
|
||||
beyond its core role of issue tracking into supporting the different work item types and handling
|
||||
logic and structure differences.
|
||||
- New functionality is typically implemented with first class objects that import behavior from issues via
|
||||
shared concerns. This leads to duplicated effort and ultimately small differences between common interactions. This
|
||||
leads to inconsistent UX.
|
||||
- Codebase maintainability and feature development becomes a bigger challenges as we grow issues
|
||||
beyond its core role of issue tracking into supporting the different types and subtle differences between them.
|
||||
|
||||
## Work item and work item type terms
|
||||
|
||||
Using the terms "issue" or "issuable" to reference the types of collaboration objects
|
||||
(for example, issue, bug, feature, or epic) often creates confusion. To avoid confusion, we will use the term
|
||||
work item type (WIT) when referring to the type of a collaboration object.
|
||||
An instance of a WIT is a work item (WI). For example, `issue#123`, `bug#456`, `requirement#789`.
|
||||
|
||||
### Migration strategy
|
||||
|
||||
WI model will be built on top of the existing `Issue` model and we'll gradually migrate `Issue`
|
||||
model code to the WI model.
|
||||
|
||||
One way to approach it is:
|
||||
|
||||
```ruby
|
||||
class WorkItems::WorkItem < ApplicationRecord
|
||||
self.table_name = 'issues'
|
||||
|
||||
# ... all the current issue.rb code
|
||||
end
|
||||
|
||||
class Issue < WorkItems::WorkItem
|
||||
# Do not add code to this class add to WorkItems:WorkItem
|
||||
end
|
||||
```
|
||||
|
||||
We already use the concept of WITs within `issues` table through `issue_type`
|
||||
column. There are `issue`, `incident`, and `test_case` issue types. To extend this
|
||||
so that in future we can allow users to define custom WITs, we will move the
|
||||
`issue_type` to a separate table: `work_item_types`. The migration process of `issue_type`
|
||||
to `work_item_types` will involve creating the set of WITs for all root-level groups.
|
||||
|
||||
NOTE:
|
||||
At first, defining a WIT will only be possible at the root-level group, which would then be inherited by sub-groups.
|
||||
We will investigate the possibility of defining new WITs at sub-group levels at a later iteration.
|
||||
|
||||
### Introducing work_item_types table
|
||||
|
||||
For example, suppose there are three root-level groups with IDs: `11`, `12`, and `13`. Also,
|
||||
assume the following base types: `issue: 0`, `incident: 1`, `test_case: 2`.
|
||||
|
||||
The respective `work_item_types` records:
|
||||
|
||||
| `group_id` | `base_type` | `title` |
|
||||
| -------------- | ----------- | --------- |
|
||||
| 11 | 0 | Issue |
|
||||
| 11 | 1 | Incident |
|
||||
| 11 | 2 | Test Case |
|
||||
| 12 | 0 | Issue |
|
||||
| 12 | 1 | Incident |
|
||||
| 12 | 2 | Test Case |
|
||||
| 13 | 0 | Issue |
|
||||
| 13 | 1 | Incident |
|
||||
| 13 | 2 | Test Case |
|
||||
|
||||
What we will do to achieve this:
|
||||
|
||||
1. Add a `work_item_type_id` column to the `issues` table.
|
||||
1. Ensure we write to both `issues#issue_type` and `issues#work_item_type_id` columns for
|
||||
new or updated issues.
|
||||
1. Backfill the `work_item_type_id` column to point to the `work_item_types#id` corresponding
|
||||
to issue's project root groups. For example:
|
||||
|
||||
```ruby
|
||||
issue.project.root_group.work_item_types.where(base_type: issue.issue_type).first.id.
|
||||
```
|
||||
|
||||
1. After `issues#work_item_type_id` is populated, we can switch our queries from
|
||||
using `issue_type` to using `work_item_type_id`.
|
||||
|
||||
To introduce a new WIT there are two options:
|
||||
|
||||
- Follow the first step of the above process. We will still need to run a migration
|
||||
that adds a new WIT for all root-level groups to make the WIT available to
|
||||
all users. Besides a long-running migration, we'll need to
|
||||
insert several million records to `work_item_types`. This might be unwanted for users
|
||||
that do not want or need additional WITs in their workflow.
|
||||
- Create an opt-in flow, so that the record in `work_item_types` for specific root-level group
|
||||
is created only when a customer opts in. However, this implies a lower discoverability
|
||||
of the newly introduced work item type.
|
||||
|
||||
### Work item type widgets
|
||||
|
||||
All WITs will share the same pool of predefined widgets and will be customized by
|
||||
which widgets are active on a specific WIT. Every attribute (column or association)
|
||||
will become a widget with self-encapsulated functionality regardless of the WIT it belongs to.
|
||||
Because any WIT can have any widget, we only need to define which widget is active for a
|
||||
specific WIT. So, after switching the type of a specific work item, we display a different set
|
||||
of widgets.
|
||||
|
||||
### Widgets metadata
|
||||
|
||||
In order to customize each WIT with corresponding active widgets we will need a data
|
||||
structure to map each WIT to specific widgets.
|
||||
|
||||
NOTE:
|
||||
The exact structure of the WITs widgets metadata is still to be defined.
|
||||
|
||||
### Custom work item types
|
||||
|
||||
With the WIT widget metadata and the workflow around mapping WIT to specific
|
||||
widgets, we will be able to expose custom WITs to the users. Users will be able
|
||||
to create their own WITs and customize them with widgets from the predefined pool.
|
||||
|
||||
### Custom widgets
|
||||
|
||||
The end goal is to allow users to define custom widgets and use these custom
|
||||
widgets on any WIT. But this is a much further iteration and requires additional
|
||||
investigation to determine both data and application architecture to be used.
|
||||
|
||||
## Migrate requirements and epics to work item types
|
||||
|
||||
We'll migrate requirements and epics into work item types, with their own set
|
||||
of widgets. To achieve that, we'll migrate data to the `issues` table,
|
||||
and we'll keep current `requirements` and `epics` tables to be used as proxies for old references to ensure
|
||||
backward compatibility with already existing references.
|
||||
|
||||
### Migrate requirements to work item types
|
||||
|
||||
Currently `Requirement` attributes are a subset of `Issue` attributes, so the migration
|
||||
consists mainly of:
|
||||
|
||||
- Data migration.
|
||||
- Keeping backwards compatibility at API levels.
|
||||
- Ensuring that old references continue to work.
|
||||
|
||||
The migration to a different underlying data structure should be seamless to the end user.
|
||||
|
||||
### Migrate epics to work item types
|
||||
|
||||
`Epic` has some extra functionality that the `Issue` WIT does not currently have.
|
||||
So, migrating epics to a work item type requires providing feature parity between the current `Epic` object and WITs.
|
||||
|
||||
The main missing features are:
|
||||
|
||||
- Get WIs to the group level. This is dependent on [Consolidate Groups and Projects](https://gitlab.com/gitlab-org/architecture/tasks/-/issues/7)
|
||||
initiative.
|
||||
- A hierarchy widget: the ability to structure work items into hierarchies.
|
||||
- Inherited date widget.
|
||||
|
||||
To avoid disrupting workflows for users who are already using epics, we will introduce a new WIT
|
||||
called `Feature` that will provide feature parity with epics at the project-level. Having that combined with progress
|
||||
on [Consolidate Groups and Projects](https://gitlab.com/gitlab-org/architecture/tasks/-/issues/7) front will help us
|
||||
provide a smooth migration path of epics to WIT with minimal disruption to user workflow.
|
||||
|
||||
## Work item, work item type, and widgets roadmap
|
||||
|
||||
We will move towards work items, work item types, and custom widgets (CW) in an iterative process.
|
||||
For a rough outline of the work ahead of us, see [epic 6033](https://gitlab.com/groups/gitlab-org/-/epics/6033).
|
||||
|
|
@ -31,7 +31,7 @@ To use Akismet:
|
|||
1. Click **Show** to reveal the API key, and copy the API key's value.
|
||||
1. Sign in to GitLab as an administrator.
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **Settings > Reporting** (`/admin/application_settings/reporting`).
|
||||
1. On the left sidebar, select **Settings > Reporting** (`/admin/application_settings/reporting`).
|
||||
1. Select the **Enable Akismet** checkbox.
|
||||
1. Fill in the API key from step 3.
|
||||
1. Save the configuration.
|
||||
|
|
|
|||
|
|
@ -28,7 +28,7 @@ project, group, or instance level:
|
|||
1. *For instance-level integrations:*
|
||||
1. Sign in to GitLab as a user with the [Administrator role](../user/permissions.md).
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **Settings > Integrations**.
|
||||
1. On the left sidebar, select **Settings > Integrations**.
|
||||
1. Scroll to **Add an integration**, and select **Datadog**.
|
||||
1. Select **Active** to enable the integration.
|
||||
1. Specify the [**Datadog site**](https://docs.datadoghq.com/getting_started/site/) to send data to.
|
||||
|
|
|
|||
|
|
@ -188,7 +188,7 @@ GitHub account` when signing in, in GitLab:
|
|||
|
||||
1. In the top-right corner, select your avatar.
|
||||
1. Select **Edit profile**.
|
||||
1. In the left sidebar, select **Account**.
|
||||
1. On the left sidebar, select **Account**.
|
||||
1. In the **Social sign-in** section, select **Connect to GitHub**.
|
||||
|
||||
After that, you should be able to sign in via GitHub successfully.
|
||||
|
|
|
|||
|
|
@ -14,7 +14,7 @@ GitLab.com generates an application ID and secret key for you to use.
|
|||
1. Sign in to GitLab.com.
|
||||
1. In the top-right corner, select your avatar.
|
||||
1. Select **Edit profile**.
|
||||
1. In the left sidebar, select **Applications**.
|
||||
1. On the left sidebar, select **Applications**.
|
||||
1. Provide the required details for **Add new application**.
|
||||
- Name: This can be anything. Consider something like `<Organization>'s GitLab` or `<Your Name>'s GitLab` or something else descriptive.
|
||||
- Redirect URI:
|
||||
|
|
|
|||
|
|
@ -48,7 +48,7 @@ For GitLab self-managed instances, a GitLab administrator needs to:
|
|||
to get your instance up and running.
|
||||
1. Enable it in GitLab:
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **Settings > General**.
|
||||
1. On the left sidebar, select **Settings > General**.
|
||||
1. Expand the **Gitpod** configuration section.
|
||||
1. Check the **Enable Gitpod integration** checkbox.
|
||||
1. Add your Gitpod instance URL (for example, `https://gitpod.example.com`).
|
||||
|
|
|
|||
|
|
@ -74,7 +74,7 @@ Create a personal access token to authorize Jenkins' access to GitLab.
|
|||
1. Sign in to GitLab as the user to be used with Jenkins.
|
||||
1. In the top-right corner, select your avatar.
|
||||
1. Select **Edit profile**.
|
||||
1. In the left sidebar, select **Access Tokens**.
|
||||
1. On the left sidebar, select **Access Tokens**.
|
||||
1. Create a personal access token with the **API** scope checkbox checked. For more details, see
|
||||
[Personal access tokens](../user/profile/personal_access_tokens.md).
|
||||
1. Record the personal access token's value, because it's required in [Configure the Jenkins server](#configure-the-jenkins-server) section.
|
||||
|
|
|
|||
|
|
@ -71,14 +71,14 @@ maintenance does not affect your integration.
|
|||
this user must have an [Administrator](../../user/permissions.md) role.
|
||||
1. Sign in as the `jira` user.
|
||||
1. In the top right corner, click the account's avatar, and select **Edit profile**.
|
||||
1. In the left sidebar, select **Applications**.
|
||||
1. On the left sidebar, select **Applications**.
|
||||
1. In the **Name** field, enter a descriptive name for the integration, such as `Jira`.
|
||||
1. In the **Redirect URI** field, enter the URI appropriate for your version of GitLab,
|
||||
replacing `<gitlab.example.com>` with your GitLab instance domain:
|
||||
- *For GitLab versions 13.0 and later* **and** *Jira versions 8.14 and later,* use the
|
||||
generated `Redirect URL` from
|
||||
[Linking GitLab accounts with Jira](https://confluence.atlassian.com/adminjiraserver/linking-gitlab-accounts-1027142272.html).
|
||||
- *For GitLab versions 13.0 and later* **and** *Jira Cloud,* use `https://<gitlab.example.com>/login/oauth/callback`.
|
||||
- *For GitLab versions 13.0 and later* **and** *Jira Cloud,* use `https://<gitlab.example.com>/login/oauth/callback`.
|
||||
- *For GitLab versions 11.3 and later* **and** *Jira versions 8.13 and earlier,* use `https://<gitlab.example.com>/login/oauth/callback`.
|
||||
If you use GitLab.com, the URL is `https://gitlab.com/login/oauth/callback`.
|
||||
- *For GitLab versions 11.2 and earlier,* use
|
||||
|
|
|
|||
|
|
@ -118,7 +118,7 @@ If you're not an administrator:
|
|||
|
||||
1. In the top-right corner, select your avatar.
|
||||
1. Select **Edit profile**.
|
||||
1. In the left sidebar, select **Account**.
|
||||
1. On the left sidebar, select **Account**.
|
||||
1. In the **Social sign-in** section, select **Connect Kerberos SPNEGO**.
|
||||
If you don't see a **Social sign-in** Kerberos option, follow the
|
||||
requirements in [Enable single sign-on](#enable-single-sign-on).
|
||||
|
|
|
|||
|
|
@ -48,7 +48,7 @@ To add a new application for your user:
|
|||
|
||||
1. In the top-right corner, select your avatar.
|
||||
1. Select **Edit profile**.
|
||||
1. In the left sidebar, select **Applications**.
|
||||
1. On the left sidebar, select **Applications**.
|
||||
1. Enter a **Name**, **Redirect URI** and OAuth 2 scopes as defined in [Authorized Applications](#authorized-applications).
|
||||
The **Redirect URI** is the URL where users are sent after they authorize with GitLab.
|
||||
1. Select **Save application**. GitLab provides:
|
||||
|
|
|
|||
|
|
@ -153,7 +153,7 @@ OmniAuth provider for an existing user.
|
|||
1. Sign in normally - whether standard sign in, LDAP, or another OmniAuth provider.
|
||||
1. In the top-right corner, select your avatar.
|
||||
1. Select **Edit profile**.
|
||||
1. In the left sidebar, select **Account**.
|
||||
1. On the left sidebar, select **Account**.
|
||||
1. In the **Connected Accounts** section, select the desired OmniAuth provider, such as Twitter.
|
||||
1. The user is redirected to the provider. After the user authorizes GitLab,
|
||||
they are redirected back to GitLab.
|
||||
|
|
@ -270,7 +270,7 @@ By default, **Sign In** is enabled by using all the OAuth Providers that have be
|
|||
To enable/disable an OmniAuth provider:
|
||||
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, go to **Settings**.
|
||||
1. On the left sidebar, go to **Settings**.
|
||||
1. Scroll to the **Sign-in Restrictions** section, and click **Expand**.
|
||||
1. Below **Enabled OAuth Sign-In sources**, select the checkbox for each provider you want to enable or disable.
|
||||
|
||||
|
|
|
|||
|
|
@ -77,7 +77,7 @@ You can skip this step if you already have your GitLab repositories searchable i
|
|||
### Configure your GitLab instance with Sourcegraph
|
||||
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **Settings > General**.
|
||||
1. On the left sidebar, select **Settings > General**.
|
||||
1. Expand the **Sourcegraph** configuration section.
|
||||
1. Check **Enable Sourcegraph**.
|
||||
1. Set the Sourcegraph URL to your Sourcegraph instance, such as `https://sourcegraph.example.com`.
|
||||
|
|
|
|||
|
|
@ -42,7 +42,7 @@ To find it in GitLab:
|
|||
|
||||
1. In the top-right corner, select your avatar.
|
||||
1. Select **Edit profile**.
|
||||
1. In the left sidebar, select **Access Tokens**.
|
||||
1. On the left sidebar, select **Access Tokens**.
|
||||
|
||||
Learn more about generating a personal access token in the
|
||||
[Personal Access Token Documentation](../user/profile/personal_access_tokens.md).
|
||||
|
|
|
|||
|
|
@ -23,7 +23,7 @@ The following assumes you already have Vault installed and running.
|
|||
|
||||
1. In the top-right corner, select your avatar.
|
||||
1. Select **Edit profile**.
|
||||
1. In the left sidebar, select **Applications**.
|
||||
1. On the left sidebar, select **Applications**.
|
||||
1. Fill out the application **Name** and [**Redirect URI**](https://www.vaultproject.io/docs/auth/jwt#redirect-uris).
|
||||
1. Select the **OpenID** scope.
|
||||
1. Select **Save application**.
|
||||
|
|
|
|||
|
|
@ -19,7 +19,7 @@ To change your username:
|
|||
|
||||
1. In the top-right corner, select your avatar.
|
||||
1. Select **Edit profile**.
|
||||
1. In the left sidebar, select **Account**.
|
||||
1. On the left sidebar, select **Account**.
|
||||
1. In the **Change username** section, type the new username.
|
||||
1. Select **Update username**.
|
||||
|
||||
|
|
|
|||
|
|
@ -47,7 +47,7 @@ to `127.0.0.1`, `::1` and `0.0.0.0`, as well as IPv4 `10.0.0.0/8`, `172.16.0.0/1
|
|||
This behavior can be overridden:
|
||||
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **Settings > Network**.
|
||||
1. On the left sidebar, select **Settings > Network**.
|
||||
1. Expand the **Outbound requests** section:
|
||||

|
||||
1. Select **Allow requests to the local network from web hooks and services**.
|
||||
|
|
@ -66,7 +66,7 @@ and *webhooks* even when local requests are not allowed by adding them to the
|
|||
allowlist:
|
||||
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **Settings > Network** (`/admin/application_settings/network`)
|
||||
1. On the left sidebar, select **Settings > Network** (`/admin/application_settings/network`)
|
||||
and expand **Outbound requests**:
|
||||
|
||||

|
||||
|
|
|
|||
|
|
@ -339,7 +339,7 @@ Quotas apply to:
|
|||
|
||||
1. In the top-right corner, select your avatar.
|
||||
1. Select **Edit profile**.
|
||||
1. In the left sidebar, select **[Usage Quotas](https://gitlab.com/-/profile/usage_quotas#pipelines-quota-tab)**.
|
||||
1. On the left sidebar, select **[Usage Quotas](https://gitlab.com/-/profile/usage_quotas#pipelines-quota-tab)**.
|
||||
|
||||
Only pipeline minutes for GitLab shared runners are restricted. If you have a
|
||||
specific runner set up for your projects, there is no limit to your build time on GitLab SaaS.
|
||||
|
|
@ -375,7 +375,7 @@ To purchase additional minutes for your personal namespace:
|
|||
|
||||
1. In the top-right corner, select your avatar.
|
||||
1. Select **Edit profile**.
|
||||
1. In the left sidebar, select **Usage Quotas**.
|
||||
1. On the left sidebar, select **Usage Quotas**.
|
||||
1. Select **Buy additional minutes** and GitLab redirects you to the Customers Portal.
|
||||
1. Locate the subscription card that's linked to your personal namespace on GitLab SaaS, click **Buy more CI minutes**, and complete the details about the transaction. Once we have processed your payment, the extra CI minutes are synced to your personal namespace.
|
||||
1. To confirm the available CI minutes for your personal projects, go to the **Usage Quotas** settings again.
|
||||
|
|
|
|||
|
|
@ -53,7 +53,7 @@ for Push and Tag events, but we never display commits.
|
|||
To create a system hook:
|
||||
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **System Hooks**.
|
||||
1. On the left sidebar, select **System Hooks**.
|
||||
1. Provide the **URL** and **Secret Token**.
|
||||
1. Select the checkbox next to each **Trigger** you want to enable.
|
||||
1. Select **Enable SSL verification**, if desired.
|
||||
|
|
|
|||
|
|
@ -23,7 +23,7 @@ For information about email notifications originating from GitLab, read
|
|||
## Sending emails to users from within GitLab
|
||||
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **Overview > Users**.
|
||||
1. On the left sidebar, select **Overview > Users**.
|
||||
1. Select **Send email to users**.
|
||||
|
||||

|
||||
|
|
|
|||
|
|
@ -6,7 +6,6 @@ info: To determine the technical writer assigned to the Stage/Group associated w
|
|||
|
||||
# Tutorial: Use Auto DevOps to deploy an application to Google Kubernetes Engine **(FREE)**
|
||||
|
||||
This step-by-step guide helps you use [Auto DevOps](index.md) to
|
||||
In this tutorial, we'll help you to get started with [Auto DevOps](index.md)
|
||||
through an example of how to deploy an application to Google Kubernetes Engine (GKE).
|
||||
|
||||
|
|
|
|||
|
|
@ -12,7 +12,7 @@ There are several options for customizing the appearance of a self-managed insta
|
|||
of GitLab. To access these settings:
|
||||
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **Settings > Appearance**.
|
||||
1. On the left sidebar, select **Settings > Appearance**.
|
||||
|
||||
## Navigation bar
|
||||
|
||||
|
|
|
|||
|
|
@ -34,7 +34,7 @@ set values are presented as **Too large** are cannot be expanded in the UI.
|
|||
To configure these values:
|
||||
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **Settings > General**.
|
||||
1. On the left sidebar, select **Settings > General**.
|
||||
1. Expand **Diff limits**.
|
||||
1. Enter a value for the diff limit.
|
||||
1. Select **Save changes**.
|
||||
|
|
|
|||
|
|
@ -72,7 +72,7 @@ You can administer all projects in the GitLab instance from the Admin Area's Pro
|
|||
To access the Projects page:
|
||||
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **Overview > Projects**.
|
||||
1. On the left sidebar, select **Overview > Projects**.
|
||||
1. Select the **All**, **Private**, **Internal**, or **Public** tab to list only
|
||||
projects of that criteria.
|
||||
|
||||
|
|
@ -112,7 +112,7 @@ You can combine the filter options. For example, to list only public projects wi
|
|||
You can administer all users in the GitLab instance from the Admin Area's Users page:
|
||||
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **Overview > Users**.
|
||||
1. On the left sidebar, select **Overview > Users**.
|
||||
|
||||
To list users matching a specific criteria, click on one of the following tabs on the **Users** page:
|
||||
|
||||
|
|
@ -157,7 +157,7 @@ You can impersonate a user in the following ways:
|
|||
|
||||
- Through the UI:
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **Overview > Users**.
|
||||
1. On the left sidebar, select **Overview > Users**.
|
||||
1. From the list of users, select a user.
|
||||
1. Select **Impersonate**.
|
||||
- With the API, using [impersonation tokens](../../api/index.md#impersonation-tokens).
|
||||
|
|
@ -210,7 +210,7 @@ You can administer all groups in the GitLab instance from the Admin Area's Group
|
|||
To access the Groups page:
|
||||
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **Overview > Groups**.
|
||||
1. On the left sidebar, select **Overview > Groups**.
|
||||
|
||||
For each group, the page displays their name, description, size, number of projects in the group,
|
||||
number of members, and whether the group is private, internal, or public. To edit a group, click
|
||||
|
|
@ -232,7 +232,7 @@ You can administer all jobs in the GitLab instance from the Admin Area's Jobs pa
|
|||
To access the Jobs page:
|
||||
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **Overview > Jobs**. All jobs are listed, in descending order of job ID.
|
||||
1. On the left sidebar, select **Overview > Jobs**. All jobs are listed, in descending order of job ID.
|
||||
1. Click the **All** tab to list all jobs. Click the **Pending**, **Running**, or **Finished**
|
||||
tab to list only jobs of that status.
|
||||
|
||||
|
|
@ -258,7 +258,7 @@ You can administer all runners in the GitLab instance from the Admin Area's **Ru
|
|||
To access the **Runners** page:
|
||||
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **Overview > Runners**.
|
||||
1. On the left sidebar, select **Overview > Runners**.
|
||||
|
||||
The **Runners** page features:
|
||||
|
||||
|
|
@ -308,7 +308,7 @@ page. For more details, see [Gitaly](../../administration/gitaly/index.md).
|
|||
To access the **Gitaly Servers** page:
|
||||
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **Overview > Gitaly Servers**.
|
||||
1. On the left sidebar, select **Overview > Gitaly Servers**.
|
||||
|
||||
For each Gitaly server, the following details are listed:
|
||||
|
||||
|
|
|
|||
|
|
@ -16,7 +16,7 @@ project level.
|
|||
To enable merge request approval rules for an instance:
|
||||
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **{push-rules}** **Push Rules**, and expand **Merge request (MR) approvals**.
|
||||
1. On the left sidebar, select **{push-rules}** **Push Rules**, and expand **Merge request (MR) approvals**.
|
||||
1. Set the required rule.
|
||||
1. Click **Save changes**.
|
||||
|
||||
|
|
|
|||
|
|
@ -147,7 +147,7 @@ An access token needs to be provided while accessing the probe endpoints. You ca
|
|||
find the current accepted token in the user interface:
|
||||
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **Monitoring > Health Check**. (`admin/health_check`)
|
||||
1. On the left sidebar, select **Monitoring > Health Check**. (`admin/health_check`)
|
||||
|
||||

|
||||
|
||||
|
|
|
|||
|
|
@ -12,7 +12,7 @@ type: reference
|
|||
You can change the default maximum number of projects that users can create in their personal namespace:
|
||||
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **Settings > General**, then expand **Account and limit**.
|
||||
1. On the left sidebar, select **Settings > General**, then expand **Account and limit**.
|
||||
1. Increase or decrease that **Default projects limit** value.
|
||||
|
||||
If you set **Default projects limit** to 0, users are not allowed to create projects
|
||||
|
|
@ -23,7 +23,7 @@ in their users personal namespace. However, projects can still be created in a g
|
|||
You can change the maximum file size for attachments in comments and replies in GitLab:
|
||||
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **Settings > General**, then expand **Account and limit**.
|
||||
1. On the left sidebar, select **Settings > General**, then expand **Account and limit**.
|
||||
1. Increase or decrease by changing the value in **Maximum attachment size (MB)**.
|
||||
|
||||
NOTE:
|
||||
|
|
@ -36,7 +36,7 @@ details.
|
|||
You can change the maximum push size for your repository:
|
||||
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **Settings > General**, then expand **Account and limit**.
|
||||
1. On the left sidebar, select **Settings > General**, then expand **Account and limit**.
|
||||
1. Increase or decrease by changing the value in **Maximum push size (MB)**.
|
||||
|
||||
NOTE:
|
||||
|
|
@ -51,7 +51,7 @@ Use [Git LFS](../../../topics/git/lfs/index.md) to add large files to a reposito
|
|||
You can change the maximum file size for imports in GitLab:
|
||||
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **Settings > General**, then expand **Account and limit**.
|
||||
1. On the left sidebar, select **Settings > General**, then expand **Account and limit**.
|
||||
1. Increase or decrease by changing the value in **Maximum import size (MB)**.
|
||||
|
||||
NOTE:
|
||||
|
|
@ -71,7 +71,7 @@ Only a GitLab administrator can set the prefix, which is a global setting applie
|
|||
to any PAT generated in the system by any user:
|
||||
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **Settings > General**.
|
||||
1. On the left sidebar, select **Settings > General**.
|
||||
1. Expand the **Account and limit** section.
|
||||
1. Fill in the **Personal Access Token prefix** field.
|
||||
1. Click **Save changes**.
|
||||
|
|
@ -114,7 +114,7 @@ These settings can be found in:
|
|||
1. Click **Save changes**.
|
||||
- GitLab global settings:
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **Settings > General**.
|
||||
1. On the left sidebar, select **Settings > General**.
|
||||
1. Expand the **Account and limit** section.
|
||||
1. Fill in the **Size limit per repository (MB)** field.
|
||||
1. Click **Save changes**.
|
||||
|
|
@ -166,7 +166,7 @@ GitLab administrators can choose to customize the session duration (in minutes)
|
|||
To set a limit on how long these sessions are valid:
|
||||
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **Settings > General**.
|
||||
1. On the left sidebar, select **Settings > General**.
|
||||
1. Expand the **Account and limit** section.
|
||||
1. Fill in the **Session duration for Git operations when 2FA is enabled (minutes)** field.
|
||||
1. Click **Save changes**.
|
||||
|
|
@ -191,7 +191,7 @@ there are no restrictions.
|
|||
To set a lifetime on how long personal access tokens are valid:
|
||||
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **Settings > General**.
|
||||
1. On the left sidebar, select **Settings > General**.
|
||||
1. Expand the **Account and limit** section.
|
||||
1. Fill in the **Maximum allowable lifetime for personal access tokens (days)** field.
|
||||
1. Click **Save changes**.
|
||||
|
|
@ -214,7 +214,7 @@ By default, expired SSH keys **are not usable**.
|
|||
To allow the use of expired SSH keys:
|
||||
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **Settings > General**.
|
||||
1. On the left sidebar, select **Settings > General**.
|
||||
1. Expand the **Account and limit** section.
|
||||
1. Uncheck the **Enforce SSH key expiration** checkbox.
|
||||
|
||||
|
|
@ -230,7 +230,7 @@ By default, expired personal access tokens (PATs) **are not usable**.
|
|||
To allow the use of expired PATs:
|
||||
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **Settings > General**.
|
||||
1. On the left sidebar, select **Settings > General**.
|
||||
1. Expand the **Account and limit** section.
|
||||
1. Uncheck the **Enforce personal access token expiration** checkbox.
|
||||
|
||||
|
|
@ -243,7 +243,7 @@ To maintain integrity of user details in [Audit Events](../../../administration/
|
|||
To do this:
|
||||
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **Settings > General**, then expand **Account and limit**.
|
||||
1. On the left sidebar, select **Settings > General**, then expand **Account and limit**.
|
||||
1. Select the **Prevent users from changing their profile name** checkbox.
|
||||
|
||||
NOTE:
|
||||
|
|
|
|||
|
|
@ -42,7 +42,7 @@ the [Omnibus GitLab documentation](https://docs.gitlab.com/omnibus/settings/logs
|
|||
The external authorization service can be enabled by an administrator:
|
||||
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **Settings > General**:
|
||||
1. On the left sidebar, select **Settings > General**:
|
||||

|
||||
|
||||
The available required properties are:
|
||||
|
|
|
|||
|
|
@ -23,7 +23,7 @@ Permissions-Policy: interest-cohort=()
|
|||
To enable it:
|
||||
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **Settings > General**.
|
||||
1. On the left sidebar, select **Settings > General**.
|
||||
1. Expand **Federated Learning of Cohorts**.
|
||||
1. Check the box.
|
||||
1. Click **Save changes**.
|
||||
|
|
|
|||
|
|
@ -85,7 +85,7 @@ You can redirect these `/help` links to either:
|
|||
- A destination that meets [necessary requirements](#destination-requirements).
|
||||
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **Settings > Preferences**.
|
||||
1. On the left sidebar, select **Settings > Preferences**.
|
||||
1. Expand **Sign-in and Help page**.
|
||||
1. In the **Documentation pages URL** field, enter the URL.
|
||||
1. Select **Save changes**.
|
||||
|
|
|
|||
|
|
@ -18,7 +18,7 @@ documentation for all current settings and limits on the GitLab.com instance.
|
|||
To access the default page for Admin Area settings:
|
||||
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **Settings > General**.
|
||||
1. On the left sidebar, select **Settings > General**.
|
||||
|
||||
| Option | Description |
|
||||
| ------ | ----------- |
|
||||
|
|
@ -127,5 +127,5 @@ You can change the [Default first day of the week](../../profile/preferences.md)
|
|||
for the entire GitLab instance:
|
||||
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **Settings > Preferences**.
|
||||
1. On the left sidebar, select **Settings > Preferences**.
|
||||
1. Scroll to the **Localization** section, and select your desired first day of the week.
|
||||
|
|
|
|||
|
|
@ -20,7 +20,7 @@ while the project remains secure.
|
|||
To select a project to serve as the custom template repository:
|
||||
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **Settings > Templates**.
|
||||
1. On the left sidebar, select **Settings > Templates**.
|
||||
1. Select the project:
|
||||
|
||||

|
||||
|
|
|
|||
|
|
@ -23,7 +23,7 @@ Only the complete settings for an integration can be inherited. Per-field inheri
|
|||
> - [Introduced](https://gitlab.com/groups/gitlab-org/-/epics/2543) in GitLab 13.6 for group-level integrations.
|
||||
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **Settings > Integrations**.
|
||||
1. On the left sidebar, select **Settings > Integrations**.
|
||||
1. Select an integration.
|
||||
1. Enter configuration details and click **Save changes**.
|
||||
|
||||
|
|
@ -55,7 +55,7 @@ integration on all non-configured groups and projects by default.
|
|||
### Remove an instance-level default setting
|
||||
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **Settings > Integrations**.
|
||||
1. On the left sidebar, select **Settings > Integrations**.
|
||||
1. Select an integration.
|
||||
1. Click **Reset** and confirm.
|
||||
|
||||
|
|
@ -69,7 +69,7 @@ You can view which projects in your instance use custom settings that [override
|
|||
for an integration.
|
||||
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **Settings > Integrations**.
|
||||
1. On the left sidebar, select **Settings > Integrations**.
|
||||
1. Select an integration.
|
||||
1. Select the **Projects using custom settings** tab.
|
||||
|
||||
|
|
|
|||
|
|
@ -27,7 +27,7 @@ To modify this setting:
|
|||
|
||||
- In the Admin Area:
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **Settings > Network**, then expand **Performance optimization**.
|
||||
1. On the left sidebar, select **Settings > Network**, then expand **Performance optimization**.
|
||||
- Through the [Application settings API](../../../api/settings.md#list-of-settings-that-can-be-accessed-via-api-calls)
|
||||
as `push_event_activities_limit`.
|
||||
|
||||
|
|
|
|||
|
|
@ -12,7 +12,7 @@ type: reference
|
|||
This setting defaults to `300` requests per minute, and allows you to rate limit the requests to raw endpoints:
|
||||
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **Settings > Network**.
|
||||
1. On the left sidebar, select **Settings > Network**.
|
||||
1. Expand **Performance optimization**.
|
||||
|
||||
For example, requests over `300` per minute to `https://gitlab.com/gitlab-org/gitlab-foss/raw/master/app/controllers/application_controller.rb` are blocked. Access to the raw file is released after 1 minute.
|
||||
|
|
|
|||
|
|
@ -14,7 +14,7 @@ You can use **Sign-in restrictions** to customize authentication restrictions fo
|
|||
To access sign-in restriction settings:
|
||||
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **Settings > General**.
|
||||
1. On the left sidebar, select **Settings > General**.
|
||||
1. Expand the **Sign-in restrictions** section.
|
||||
|
||||
## Password authentication enabled
|
||||
|
|
@ -118,7 +118,7 @@ For example, if you include the following information in the noted text box:
|
|||
To access this text box:
|
||||
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **Settings > General**, and expand the **Sign-in restrictions** section.
|
||||
1. On the left sidebar, select **Settings > General**, and expand the **Sign-in restrictions** section.
|
||||
```
|
||||
|
||||
Your users see the **Custom sign-in text** when they navigate to the sign-in screen for your
|
||||
|
|
|
|||
|
|
@ -23,7 +23,7 @@ you do not expect public users to sign up for an account.
|
|||
To disable sign ups:
|
||||
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **Settings > General**, and expand **Sign-up restrictions**.
|
||||
1. On the left sidebar, select **Settings > General**, and expand **Sign-up restrictions**.
|
||||
1. Clear the **Sign-up enabled** checkbox, then select **Save changes**.
|
||||
|
||||
## Require administrator approval for new sign ups
|
||||
|
|
@ -39,7 +39,7 @@ enabled by default for new GitLab instances. It is only applicable if sign ups a
|
|||
To require administrator approval for new sign ups:
|
||||
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **Settings > General**, and expand **Sign-up restrictions**.
|
||||
1. On the left sidebar, select **Settings > General**, and expand **Sign-up restrictions**.
|
||||
1. Select the **Require admin approval for new sign-ups** checkbox, then select **Save changes**.
|
||||
|
||||
In [GitLab 13.7 and later](https://gitlab.com/gitlab-org/gitlab/-/issues/273258), if an administrator disables this setting, the users in pending approval state are
|
||||
|
|
@ -53,7 +53,7 @@ their email address before they are allowed to sign in.
|
|||
To enforce confirmation of the email address used for new sign ups:
|
||||
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **Settings > General**, and expand **Sign-up restrictions**.
|
||||
1. On the left sidebar, select **Settings > General**, and expand **Sign-up restrictions**.
|
||||
1. Select the **Enable email restrictions for sign ups** checkbox, then select **Save changes**.
|
||||
|
||||
## User cap **(FREE SELF)**
|
||||
|
|
@ -71,7 +71,7 @@ user cap, the users in pending approval state are automatically approved in a ba
|
|||
### Set the user cap number
|
||||
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **Settings > General**.
|
||||
1. On the left sidebar, select **Settings > General**.
|
||||
1. Expand **Sign-up restrictions**.
|
||||
1. Enter a number in **User cap**.
|
||||
1. Select **Save changes**.
|
||||
|
|
@ -81,7 +81,7 @@ New user sign ups are subject to the user cap restriction.
|
|||
## Remove the user cap
|
||||
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **Settings > General**.
|
||||
1. On the left sidebar, select **Settings > General**.
|
||||
1. Expand **Sign-up restrictions**.
|
||||
1. Remove the number from **User cap**.
|
||||
1. Select **Save changes**.
|
||||
|
|
@ -139,7 +139,7 @@ reduce the risk of malicious users creating spam accounts with disposable email
|
|||
To create an email domain allowlist or denylist:
|
||||
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **Settings > General**, and expand **Sign-up restrictions**.
|
||||
1. On the left sidebar, select **Settings > General**, and expand **Sign-up restrictions**.
|
||||
1. For the allowlist, you must enter the list manually. For the denylist, you can enter the list
|
||||
manually or upload a `.txt` file that contains list entries.
|
||||
|
||||
|
|
|
|||
|
|
@ -18,7 +18,7 @@ for example `https://gitlab.example.com/-/users/terms`.
|
|||
To enforce acceptance of a Terms of Service and Privacy Policy:
|
||||
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **Settings > General**.
|
||||
1. On the left sidebar, select **Settings > General**.
|
||||
1. Expand the **Terms of Service and Privacy Policy** section.
|
||||
1. Check the **All users must accept the Terms of Service and Privacy Policy to access GitLab** checkbox.
|
||||
1. Input the text of the **Terms of Service and Privacy Policy**. You can use [Markdown](../../markdown.md)
|
||||
|
|
|
|||
|
|
@ -20,7 +20,7 @@ The following limits are disabled by default:
|
|||
To enforce any or all of them:
|
||||
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **Settings > Network**, and expand **User and IP rate limits**:
|
||||
1. On the left sidebar, select **Settings > Network**, and expand **User and IP rate limits**:
|
||||

|
||||
|
||||
NOTE:
|
||||
|
|
|
|||
|
|
@ -14,7 +14,7 @@ To access the visibility and access control options:
|
|||
|
||||
1. Sign in to GitLab as a user with [Administrator role](../../permissions.md).
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **Settings > General**.
|
||||
1. On the left sidebar, select **Settings > General**.
|
||||
1. Expand the **Visibility and access controls** section.
|
||||
|
||||
## Protect default branches
|
||||
|
|
@ -34,7 +34,7 @@ To change the default branch protection for the entire instance:
|
|||
|
||||
1. Sign in to GitLab as a user with [Administrator role](../../permissions.md).
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **Settings > General**.
|
||||
1. On the left sidebar, select **Settings > General**.
|
||||
1. Expand the **Visibility and access controls** section.
|
||||
1. Select a **Default branch protection**:
|
||||
- **Not protected** - Both developers and maintainers can push new commits,
|
||||
|
|
@ -60,7 +60,7 @@ disable this privilege for group owners, enforcing the instance-level protection
|
|||
|
||||
1. Sign in to GitLab as a user with [Administrator role](../../permissions.md).
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **Settings > General**.
|
||||
1. On the left sidebar, select **Settings > General**.
|
||||
1. Expand the **Visibility and access controls** section.
|
||||
1. Deselect the **Allow owners to manage default branch protection per group** checkbox.
|
||||
1. Select **Save changes**.
|
||||
|
|
@ -76,7 +76,7 @@ on the instance. To alter which roles have permission to create projects:
|
|||
|
||||
1. Sign in to GitLab as a user with [Administrator role](../../permissions.md).
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **Settings > General**.
|
||||
1. On the left sidebar, select **Settings > General**.
|
||||
1. Expand the **Visibility and access controls** section.
|
||||
1. For **Default project creation protection**, select the desired roles:
|
||||
- No one.
|
||||
|
|
@ -91,7 +91,7 @@ delete a project. To allow only users with the Administrator role to delete proj
|
|||
|
||||
1. Sign in to GitLab as a user with [Administrator role](../../permissions.md).
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **Settings > General**.
|
||||
1. On the left sidebar, select **Settings > General**.
|
||||
1. Expand the **Visibility and access controls** section.
|
||||
1. Scroll to **Default project deletion protection**, and select **Only admins can delete project**.
|
||||
1. Select **Save changes**.
|
||||
|
|
@ -143,7 +143,7 @@ To set the default [visibility levels for new projects](../../../public_access/p
|
|||
|
||||
1. Sign in to GitLab as a user with [Administrator role](../../permissions.md).
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **Settings > General**.
|
||||
1. On the left sidebar, select **Settings > General**.
|
||||
1. Expand the **Visibility and access controls** section.
|
||||
1. Select the desired default project visibility:
|
||||
- **Private** - Project access must be granted explicitly to each user. If this
|
||||
|
|
@ -158,7 +158,7 @@ To set the default visibility levels for new [snippets](../../snippets.md):
|
|||
|
||||
1. Sign in to GitLab as a user with [Administrator role](../../permissions.md).
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **Settings > General**.
|
||||
1. On the left sidebar, select **Settings > General**.
|
||||
1. Expand the **Visibility and access controls** section.
|
||||
1. Select the desired default snippet visibility.
|
||||
1. Select **Save changes**.
|
||||
|
|
@ -172,7 +172,7 @@ To set the default visibility levels for new groups:
|
|||
|
||||
1. Sign in to GitLab as a user with [Administrator role](../../permissions.md).
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **Settings > General**.
|
||||
1. On the left sidebar, select **Settings > General**.
|
||||
1. Expand the **Visibility and access controls** section.
|
||||
1. Select the desired default group visibility:
|
||||
- **Private** - The group and its projects can only be viewed by members.
|
||||
|
|
@ -189,7 +189,7 @@ To restrict visibility levels for projects, snippets, and selected pages:
|
|||
|
||||
1. Sign in to GitLab as a user with [Administrator role](../../permissions.md).
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **Settings > General**.
|
||||
1. On the left sidebar, select **Settings > General**.
|
||||
1. Expand the **Visibility and access controls** section.
|
||||
1. In the **Restricted visibility levels** section, select the desired visibility levels to restrict.
|
||||
1. Select **Save changes**.
|
||||
|
|
@ -203,7 +203,7 @@ You can specify from which hosting sites users can [import their projects](../..
|
|||
|
||||
1. Sign in to GitLab as a user with [Administrator role](../../permissions.md).
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **Settings > General**.
|
||||
1. On the left sidebar, select **Settings > General**.
|
||||
1. Expand the **Visibility and access controls** section.
|
||||
1. Select each of **Import sources** to allow.
|
||||
1. Select **Save changes**.
|
||||
|
|
@ -215,7 +215,7 @@ To enable the export of
|
|||
|
||||
1. Sign in to GitLab as a user with [Administrator role](../../permissions.md).
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **Settings > General**.
|
||||
1. On the left sidebar, select **Settings > General**.
|
||||
1. Expand the **Visibility and access controls** section.
|
||||
1. Select **Project export enabled**.
|
||||
1. Select **Save changes**.
|
||||
|
|
@ -231,7 +231,7 @@ To specify the enabled Git access protocols:
|
|||
|
||||
1. Sign in to GitLab as a user with [Administrator role](../../permissions.md).
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **Settings > General**.
|
||||
1. On the left sidebar, select **Settings > General**.
|
||||
1. Expand the **Visibility and access controls** section.
|
||||
1. Select the desired Git access protocols:
|
||||
- Both SSH and HTTP(S)
|
||||
|
|
|
|||
|
|
@ -11,7 +11,7 @@ You can analyze your users' GitLab activities over time.
|
|||
To view user cohorts:
|
||||
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **Overview > Users**.
|
||||
1. On the left sidebar, select **Overview > Users**.
|
||||
1. Select the **Cohorts** tab.
|
||||
|
||||
## Overview
|
||||
|
|
|
|||
|
|
@ -13,7 +13,7 @@ GitLab encourages communication through comments, threads, and
|
|||
There are two types of comments:
|
||||
|
||||
- A standard comment.
|
||||
- A comment in a thread, which has to be resolved.
|
||||
- A comment in a thread, which can be [resolved](#resolve-a-thread).
|
||||
|
||||
In a comment, you can enter [Markdown](../markdown.md) and use [quick actions](../project/quick_actions.md).
|
||||
|
||||
|
|
@ -218,16 +218,16 @@ A threaded comment is created.
|
|||
## Resolve a thread
|
||||
|
||||
> - [Introduced](https://gitlab.com/gitlab-org/gitlab-foss/-/merge_requests/5022) in GitLab 8.11.
|
||||
> - Resolvable threads can be added only to merge request diffs.
|
||||
> - Resolving comments individually was [removed](https://gitlab.com/gitlab-org/gitlab/-/issues/28750) in GitLab 13.6.
|
||||
|
||||
You can resolve a thread when you want to finish a conversation.
|
||||
In a merge request, you can resolve a thread when you want to finish a conversation.
|
||||
|
||||
Prerequisites:
|
||||
|
||||
- You must have at least the [Developer role](../permissions.md#project-members-permissions)
|
||||
or be the author of the change being reviewed.
|
||||
- You must be in an issue, merge request, commit, or snippet.
|
||||
- Resolvable threads can be added only to merge requests. It doesn't work
|
||||
for comments in issues, commits, or snippets.
|
||||
|
||||
To resolve a thread:
|
||||
|
||||
|
|
|
|||
|
|
@ -316,7 +316,7 @@ In GitLab 13.11, you can optionally replace the sharing form with a modal window
|
|||
To share a group after enabling this feature:
|
||||
|
||||
1. Go to your group's page.
|
||||
1. In the left sidebar, go to **Group information > Members**, and then select **Invite a group**.
|
||||
1. On the left sidebar, go to **Group information > Members**, and then select **Invite a group**.
|
||||
1. Select a group, and select a **Max role**.
|
||||
1. (Optional) Select an **Access expiration date**.
|
||||
1. Select **Invite**.
|
||||
|
|
|
|||
|
|
@ -310,7 +310,7 @@ For example, to unlink the `MyOrg` account:
|
|||
|
||||
1. In the top-right corner, select your avatar.
|
||||
1. Select **Edit profile**.
|
||||
1. In the left sidebar, select **Account**.
|
||||
1. On the left sidebar, select **Account**.
|
||||
1. In the **Social sign-in** section, select **Disconnect** next to the connected account.
|
||||
|
||||

|
||||
|
|
|
|||
|
|
@ -69,7 +69,7 @@ Users with the [Owner role](../../permissions.md) for a group can export the
|
|||
contents of that group:
|
||||
|
||||
1. On the top bar, select **Menu >** **Groups** and find your group.
|
||||
1. In the left sidebar, select **Settings**.
|
||||
1. On the left sidebar, select **Settings**.
|
||||
1. Scroll to the **Advanced** section, and select **Export Group**.
|
||||
1. After the export is generated, you should receive an email with a link to the [exported contents](#exported-contents)
|
||||
in a compressed tar archive, with contents in NDJSON format.
|
||||
|
|
|
|||
|
|
@ -17,7 +17,7 @@ projects.
|
|||
To view the instance level Kubernetes clusters:
|
||||
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **Kubernetes**.
|
||||
1. On the left sidebar, select **Kubernetes**.
|
||||
|
||||
## Cluster precedence
|
||||
|
||||
|
|
|
|||
|
|
@ -41,6 +41,10 @@ PUT /projects/:id/packages/terraform/modules/:module_name/:module_system/:module
|
|||
|
||||
Provide the file content in the request body.
|
||||
|
||||
Note that, in the following example, the request must end with `/file`.
|
||||
If you send a request ending with something else, it results in a 404
|
||||
error `{"error":"404 Not Found"}`.
|
||||
|
||||
Example request using a personal access token:
|
||||
|
||||
```shell
|
||||
|
|
|
|||
|
|
@ -21,7 +21,7 @@ As a user, to delete your own account:
|
|||
|
||||
1. In the top-right corner, select your avatar.
|
||||
1. Select **Edit profile**.
|
||||
1. In the left sidebar, select **Account**.
|
||||
1. On the left sidebar, select **Account**.
|
||||
1. Select **Delete account**.
|
||||
|
||||
## As an administrator
|
||||
|
|
|
|||
|
|
@ -18,7 +18,7 @@ To list all active sessions:
|
|||
|
||||
1. In the top-right corner, select your avatar.
|
||||
1. Select **Edit profile**.
|
||||
1. In the left sidebar, select **Active Sessions**.
|
||||
1. On the left sidebar, select **Active Sessions**.
|
||||
|
||||

|
||||
|
||||
|
|
@ -35,7 +35,7 @@ To revoke an active session:
|
|||
|
||||
1. In the top-right corner, select your avatar.
|
||||
1. Select **Edit profile**.
|
||||
1. In the left sidebar, select **Active Sessions**.
|
||||
1. On the left sidebar, select **Active Sessions**.
|
||||
1. Select **Revoke** next to a session. The current session cannot be revoked, as this would sign you out of GitLab.
|
||||
|
||||
NOTE:
|
||||
|
|
|
|||
|
|
@ -31,7 +31,7 @@ To change your password:
|
|||
|
||||
1. In the top-right corner, select your avatar.
|
||||
1. Select **Edit profile**.
|
||||
1. In the left sidebar, select **Password**.
|
||||
1. On the left sidebar, select **Password**.
|
||||
1. In the **Current password** field, enter your current password.
|
||||
1. In the **New password** and **Password confirmation** field, enter your new password.
|
||||
1. Select **Save password**.
|
||||
|
|
@ -55,7 +55,7 @@ To change your username:
|
|||
|
||||
1. In the top-right corner, select your avatar.
|
||||
1. Select **Edit profile**.
|
||||
1. In the left sidebar, select **Account**.
|
||||
1. On the left sidebar, select **Account**.
|
||||
1. In the **Change username** section, enter a new username as the path.
|
||||
1. Select **Update username**.
|
||||
|
||||
|
|
|
|||
|
|
@ -48,7 +48,7 @@ To edit your notification settings:
|
|||
|
||||
1. In the top-right corner, select your avatar.
|
||||
1. Select **Preferences**.
|
||||
1. In the left sidebar, select **Notifications**.
|
||||
1. On the left sidebar, select **Notifications**.
|
||||
1. Edit the desired notification settings. Edited settings are automatically saved and enabled.
|
||||
|
||||
## Notification scope
|
||||
|
|
@ -90,7 +90,7 @@ To select a notification level for a group, use either of these methods:
|
|||
|
||||
1. In the top-right corner, select your avatar.
|
||||
1. Select **Preferences**.
|
||||
1. In the left sidebar, select **Notifications**.
|
||||
1. On the left sidebar, select **Notifications**.
|
||||
1. Locate the project in the **Groups** section.
|
||||
1. Select the desired [notification level](#notification-levels).
|
||||
|
||||
|
|
@ -108,7 +108,7 @@ You can select an email address to receive notifications for each group you belo
|
|||
|
||||
1. In the top-right corner, select your avatar.
|
||||
1. Select **Preferences**.
|
||||
1. In the left sidebar, select **Notifications**.
|
||||
1. On the left sidebar, select **Notifications**.
|
||||
1. Locate the project in the **Groups** section.
|
||||
1. Select the desired email address.
|
||||
|
||||
|
|
@ -120,7 +120,7 @@ To select a notification level for a project, use either of these methods:
|
|||
|
||||
1. In the top-right corner, select your avatar.
|
||||
1. Select **Preferences**.
|
||||
1. In the left sidebar, select **Notifications**.
|
||||
1. On the left sidebar, select **Notifications**.
|
||||
1. Locate the project in the **Projects** section.
|
||||
1. Select the desired [notification level](#notification-levels).
|
||||
|
||||
|
|
|
|||
|
|
@ -38,7 +38,7 @@ You can create as many personal access tokens as you like.
|
|||
|
||||
1. In the top-right corner, select your avatar.
|
||||
1. Select **Edit profile**.
|
||||
1. In the left sidebar, select **Access Tokens**.
|
||||
1. On the left sidebar, select **Access Tokens**.
|
||||
1. Enter a name and optional expiry date for the token.
|
||||
1. Select the [desired scopes](#personal-access-token-scopes).
|
||||
1. Select **Create personal access token**.
|
||||
|
|
@ -62,7 +62,7 @@ At any time, you can revoke a personal access token.
|
|||
|
||||
1. In the top-right corner, select your avatar.
|
||||
1. Select **Edit profile**.
|
||||
1. In the left sidebar, select **Access Tokens**.
|
||||
1. On the left sidebar, select **Access Tokens**.
|
||||
1. In the **Active personal access tokens** area, next to the key, select **Revoke**.
|
||||
|
||||
## View the last time a token was used
|
||||
|
|
@ -74,7 +74,7 @@ To view the last time a token was used:
|
|||
|
||||
1. In the top-right corner, select your avatar.
|
||||
1. Select **Edit profile**.
|
||||
1. In the left sidebar, select **Access Tokens**.
|
||||
1. On the left sidebar, select **Access Tokens**.
|
||||
1. In the **Active personal access tokens** area, next to the key, view the **Last Used** date.
|
||||
|
||||
## Personal access token scopes
|
||||
|
|
|
|||
|
|
@ -72,7 +72,7 @@ When you're creating a new issue, these are the fields you can fill in:
|
|||
To visit the issue tracker for all projects in your group:
|
||||
|
||||
1. Go to the group dashboard.
|
||||
1. In the left sidebar, select **Issues**.
|
||||
1. On the left sidebar, select **Issues**.
|
||||
1. In the top-right, select the **Select project to create issue** button.
|
||||
1. Select the project you'd like to create an issue for. The button now reflects the selected
|
||||
project.
|
||||
|
|
|
|||
|
|
@ -59,7 +59,7 @@ In GitLab 13.11, you can optionally replace the sharing form with a modal window
|
|||
To share a project after enabling this feature:
|
||||
|
||||
1. Go to your project's page.
|
||||
1. In the left sidebar, go to **Project information > Members**, and then select **Invite a group**.
|
||||
1. On the left sidebar, go to **Project information > Members**, and then select **Invite a group**.
|
||||
1. Select a group, and select a **Max role**.
|
||||
1. (Optional) Select an **Access expiration date**.
|
||||
1. Select **Invite**.
|
||||
|
|
|
|||
|
|
@ -52,6 +52,6 @@ To sign out of your GitLab Pages website, revoke the application access token
|
|||
for GitLab Pages:
|
||||
|
||||
1. In the top menu, select your profile, and then select **Settings**.
|
||||
1. In the left sidebar, select **Applications**.
|
||||
1. On the left sidebar, select **Applications**.
|
||||
1. Scroll to the **Authorized applications** section, find the **GitLab Pages**
|
||||
entry, and select its **Revoke** button.
|
||||
|
|
|
|||
|
|
@ -64,7 +64,7 @@ customize the initial branch for projects hosted on that instance. Individual
|
|||
groups and subgroups can override this instance-wide setting for their projects.
|
||||
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **Settings > Repository**.
|
||||
1. On the left sidebar, select **Settings > Repository**.
|
||||
1. Expand **Default initial branch name**.
|
||||
1. Change the default initial branch to a custom name of your choice.
|
||||
1. Select **Save changes**.
|
||||
|
|
|
|||
|
|
@ -155,7 +155,7 @@ You can add a GPG key in your user settings:
|
|||
|
||||
1. In the top-right corner, select your avatar.
|
||||
1. Select **Edit profile**.
|
||||
1. In the left sidebar, select **GPG Keys**.
|
||||
1. On the left sidebar, select **GPG Keys**.
|
||||
1. Paste your _public_ key in the **Key** text box.
|
||||
|
||||

|
||||
|
|
@ -253,7 +253,7 @@ To revoke a GPG key:
|
|||
|
||||
1. In the top-right corner, select your avatar.
|
||||
1. Select **Edit profile**.
|
||||
1. In the left sidebar, select **GPG Keys**.
|
||||
1. On the left sidebar, select **GPG Keys**.
|
||||
1. Select **Revoke** next to the GPG key you want to delete.
|
||||
|
||||
## Removing a GPG key
|
||||
|
|
@ -267,7 +267,7 @@ To remove a GPG key from your account:
|
|||
|
||||
1. In the top-right corner, select your avatar.
|
||||
1. Select **Edit profile**.
|
||||
1. In the left sidebar, select **GPG Keys**.
|
||||
1. On the left sidebar, select **GPG Keys**.
|
||||
1. Select the trash icon (**{remove}**) next to the GPG key you want to delete.
|
||||
|
||||
## Rejecting commits that are not signed **(PREMIUM)**
|
||||
|
|
|
|||
|
|
@ -613,7 +613,7 @@ If you receive this error after creating a new project using
|
|||
Check if the repository owner is specified in the URL of your mirrored repository:
|
||||
|
||||
1. Go to your project.
|
||||
1. In the left sidebar, select **Settings > Repository**.
|
||||
1. On the left sidebar, select **Settings > Repository**.
|
||||
1. Select **Mirroring repositories**.
|
||||
1. If no repository owner is specified, delete and add the URL again in this format:
|
||||
|
||||
|
|
|
|||
|
|
@ -294,7 +294,7 @@ Live Preview is enabled for all projects on GitLab.com. If you are an administra
|
|||
of a self-managed GitLab instance, and you want to enable Live Preview:
|
||||
|
||||
1. On the top bar, select **Menu > Admin**.
|
||||
1. In the left sidebar, select **Settings > General**.
|
||||
1. On the left sidebar, select **Settings > General**.
|
||||
1. Scroll to **Web IDE** and select **Expand**:
|
||||

|
||||
1. Select **Enable Live Preview** and select **Save changes**.
|
||||
|
|
|
|||
|
|
@ -29,7 +29,7 @@ module Gitlab
|
|||
return pagination_data unless Feature.enabled?(:api_kaminari_count_with_limit, type: :ops)
|
||||
|
||||
limited_total_count = pagination_data.total_count_with_limit
|
||||
if limited_total_count > Kaminari::ActiveRecordRelationMethods::MAX_COUNT_LIMIT
|
||||
if limited_total_count > max_limit
|
||||
# The call to `total_count_with_limit` memoizes `@arel` because of a call to `references_eager_loaded_tables?`
|
||||
# We need to call `reset` because `without_count` relies on `@arel` being unmemoized
|
||||
pagination_data.reset.without_count
|
||||
|
|
@ -38,6 +38,14 @@ module Gitlab
|
|||
end
|
||||
end
|
||||
|
||||
def max_limit
|
||||
if Feature.enabled?(:lower_relation_max_count_limit, type: :ops)
|
||||
Kaminari::ActiveRecordRelationMethods::MAX_COUNT_NEW_LOWER_LIMIT
|
||||
else
|
||||
Kaminari::ActiveRecordRelationMethods::MAX_COUNT_LIMIT
|
||||
end
|
||||
end
|
||||
|
||||
def needs_pagination?(relation)
|
||||
return true unless relation.respond_to?(:current_page)
|
||||
return true if params[:page].present? && relation.current_page != params[:page].to_i
|
||||
|
|
|
|||
|
|
@ -11729,6 +11729,16 @@ msgstr ""
|
|||
msgid "DiffsCompareBaseBranch|(base)"
|
||||
msgstr ""
|
||||
|
||||
msgid "Diffs|%d addition"
|
||||
msgid_plural "Diffs|%d additions"
|
||||
msgstr[0] ""
|
||||
msgstr[1] ""
|
||||
|
||||
msgid "Diffs|%d deletion"
|
||||
msgid_plural "Diffs|%d deletions"
|
||||
msgstr[0] ""
|
||||
msgstr[1] ""
|
||||
|
||||
msgid "Diffs|No file name available"
|
||||
msgstr ""
|
||||
|
||||
|
|
@ -11738,9 +11748,17 @@ msgstr ""
|
|||
msgid "Diffs|Show all unchanged lines"
|
||||
msgstr ""
|
||||
|
||||
msgid "Diffs|Showing %{dropdownStart}%{count} changed file%{dropdownEnd}"
|
||||
msgid_plural "Diffs|Showing %{dropdownStart}%{count} changed files%{dropdownEnd}"
|
||||
msgstr[0] ""
|
||||
msgstr[1] ""
|
||||
|
||||
msgid "Diffs|Something went wrong while fetching diff lines."
|
||||
msgstr ""
|
||||
|
||||
msgid "Diffs|with %{additions} and %{deletions}"
|
||||
msgstr ""
|
||||
|
||||
msgid "Direct member"
|
||||
msgstr ""
|
||||
|
||||
|
|
@ -13297,6 +13315,9 @@ msgstr ""
|
|||
msgid "Error: %{error_message}"
|
||||
msgstr ""
|
||||
|
||||
msgid "Error: Couldn't load some or all of the changes."
|
||||
msgstr ""
|
||||
|
||||
msgid "Error: No AWS credentials were supplied"
|
||||
msgstr ""
|
||||
|
||||
|
|
@ -13635,9 +13656,6 @@ msgstr ""
|
|||
msgid "Expected documents: %{expected_documents}"
|
||||
msgstr ""
|
||||
|
||||
msgid "Experienced"
|
||||
msgstr ""
|
||||
|
||||
msgid "ExperimentSubject|Must have exactly one of User, Namespace, or Project."
|
||||
msgstr ""
|
||||
|
||||
|
|
@ -16555,9 +16573,6 @@ msgstr ""
|
|||
msgid "Hello %{name},"
|
||||
msgstr ""
|
||||
|
||||
msgid "Hello there"
|
||||
msgstr ""
|
||||
|
||||
msgid "Hello, %{name}!"
|
||||
msgstr ""
|
||||
|
||||
|
|
@ -18964,15 +18979,9 @@ msgstr ""
|
|||
msgid "Iteration|cannot be more than 500 years in the future"
|
||||
msgstr ""
|
||||
|
||||
msgid "I’m familiar with the basics of DevOps."
|
||||
msgstr ""
|
||||
|
||||
msgid "I’m joining my team who’s already on GitLab"
|
||||
msgstr ""
|
||||
|
||||
msgid "I’m not familiar with the basics of DevOps."
|
||||
msgstr ""
|
||||
|
||||
msgid "Jaeger URL"
|
||||
msgstr ""
|
||||
|
||||
|
|
@ -23130,9 +23139,6 @@ msgstr ""
|
|||
msgid "November"
|
||||
msgstr ""
|
||||
|
||||
msgid "Novice"
|
||||
msgstr ""
|
||||
|
||||
msgid "Now, personalize your GitLab experience"
|
||||
msgstr ""
|
||||
|
||||
|
|
@ -23825,6 +23831,9 @@ msgstr ""
|
|||
msgid "PackageRegistry|Composer"
|
||||
msgstr ""
|
||||
|
||||
msgid "PackageRegistry|Composer.json with license: %{license} and version: %{version}"
|
||||
msgstr ""
|
||||
|
||||
msgid "PackageRegistry|Conan"
|
||||
msgstr ""
|
||||
|
||||
|
|
@ -23888,6 +23897,9 @@ msgstr ""
|
|||
msgid "PackageRegistry|Copy require package include"
|
||||
msgstr ""
|
||||
|
||||
msgid "PackageRegistry|Copy target SHA"
|
||||
msgstr ""
|
||||
|
||||
msgid "PackageRegistry|Copy yarn command"
|
||||
msgstr ""
|
||||
|
||||
|
|
@ -24062,6 +24074,9 @@ msgstr ""
|
|||
msgid "PackageRegistry|Source project located at %{link}"
|
||||
msgstr ""
|
||||
|
||||
msgid "PackageRegistry|Target SHA: %{sha}"
|
||||
msgstr ""
|
||||
|
||||
msgid "PackageRegistry|There are no other versions of this package."
|
||||
msgstr ""
|
||||
|
||||
|
|
@ -27825,6 +27840,9 @@ msgstr ""
|
|||
msgid "Release|Something went wrong while saving the release details."
|
||||
msgstr ""
|
||||
|
||||
msgid "Reload page"
|
||||
msgstr ""
|
||||
|
||||
msgid "Remediations"
|
||||
msgstr ""
|
||||
|
||||
|
|
@ -30905,15 +30923,9 @@ msgstr ""
|
|||
msgid "Show list"
|
||||
msgstr ""
|
||||
|
||||
msgid "Show me advanced features"
|
||||
msgstr ""
|
||||
|
||||
msgid "Show me how to add a pipeline"
|
||||
msgstr ""
|
||||
|
||||
msgid "Show me the basics"
|
||||
msgstr ""
|
||||
|
||||
msgid "Show one file at a time"
|
||||
msgstr ""
|
||||
|
||||
|
|
@ -37698,9 +37710,6 @@ msgstr ""
|
|||
msgid "Welcome to GitLab,%{br_tag}%{name}!"
|
||||
msgstr ""
|
||||
|
||||
msgid "Welcome to the guided GitLab tour"
|
||||
msgstr ""
|
||||
|
||||
msgid "Welcome, %{name}!"
|
||||
msgstr ""
|
||||
|
||||
|
|
@ -37719,9 +37728,6 @@ msgstr ""
|
|||
msgid "What are you searching for?"
|
||||
msgstr ""
|
||||
|
||||
msgid "What describes you best?"
|
||||
msgstr ""
|
||||
|
||||
msgid "What does this command do?"
|
||||
msgstr ""
|
||||
|
||||
|
|
@ -37749,9 +37755,6 @@ msgstr ""
|
|||
msgid "What's new"
|
||||
msgstr ""
|
||||
|
||||
msgid "What’s your experience level?"
|
||||
msgstr ""
|
||||
|
||||
msgid "When a deployment job is successful, skip older deployment jobs that are still pending."
|
||||
msgstr ""
|
||||
|
||||
|
|
|
|||
|
|
@ -57,7 +57,7 @@
|
|||
"@gitlab/favicon-overlay": "2.0.0",
|
||||
"@gitlab/svgs": "1.211.0",
|
||||
"@gitlab/tributejs": "1.0.0",
|
||||
"@gitlab/ui": "32.9.0",
|
||||
"@gitlab/ui": "32.9.1",
|
||||
"@gitlab/visual-review-tools": "1.6.1",
|
||||
"@rails/actioncable": "6.1.3-2",
|
||||
"@rails/ujs": "6.1.3-2",
|
||||
|
|
@ -92,7 +92,7 @@
|
|||
"@tiptap/extension-task-item": "^2.0.0-beta.17",
|
||||
"@tiptap/extension-task-list": "^2.0.0-beta.17",
|
||||
"@tiptap/extension-text": "^2.0.0-beta.13",
|
||||
"@tiptap/vue-2": "^2.0.0-beta.49",
|
||||
"@tiptap/vue-2": "^2.0.0-beta.50",
|
||||
"@toast-ui/editor": "^2.5.2",
|
||||
"@toast-ui/vue-editor": "^2.5.2",
|
||||
"apollo-cache-inmemory": "^1.6.6",
|
||||
|
|
|
|||
|
|
@ -1,159 +0,0 @@
|
|||
# frozen_string_literal: true
|
||||
|
||||
require 'spec_helper'
|
||||
|
||||
RSpec.describe Registrations::ExperienceLevelsController do
|
||||
include AfterNextHelpers
|
||||
|
||||
let_it_be(:namespace) { create(:group, path: 'group-path' ) }
|
||||
let_it_be(:user) { create(:user) }
|
||||
|
||||
let(:params) { { namespace_path: namespace.to_param } }
|
||||
|
||||
describe 'GET #show' do
|
||||
subject { get :show, params: params }
|
||||
|
||||
context 'with an unauthenticated user' do
|
||||
it { is_expected.to have_gitlab_http_status(:redirect) }
|
||||
it { is_expected.to redirect_to(new_user_session_path) }
|
||||
end
|
||||
|
||||
context 'with an authenticated user' do
|
||||
before do
|
||||
sign_in(user)
|
||||
end
|
||||
|
||||
it { is_expected.to have_gitlab_http_status(:ok) }
|
||||
it { is_expected.to render_template('layouts/minimal') }
|
||||
it { is_expected.to render_template(:show) }
|
||||
end
|
||||
end
|
||||
|
||||
describe 'PUT/PATCH #update' do
|
||||
subject { patch :update, params: params }
|
||||
|
||||
context 'with an unauthenticated user' do
|
||||
it { is_expected.to have_gitlab_http_status(:redirect) }
|
||||
it { is_expected.to redirect_to(new_user_session_path) }
|
||||
end
|
||||
|
||||
context 'with an authenticated user' do
|
||||
let_it_be(:project) { build(:project, namespace: namespace, creator: user, path: 'project-path') }
|
||||
let_it_be(:issues_board) { build(:board, id: 123, project: project) }
|
||||
|
||||
before do
|
||||
sign_in(user)
|
||||
end
|
||||
|
||||
context 'when user is successfully updated' do
|
||||
context 'when no experience_level is sent' do
|
||||
before do
|
||||
user.user_preference.update_attribute(:experience_level, :novice)
|
||||
end
|
||||
|
||||
it 'will unset the user’s experience level' do
|
||||
expect { subject }.to change { user.reload.experience_level }.to(nil)
|
||||
end
|
||||
end
|
||||
|
||||
context 'when an expected experience level is sent' do
|
||||
let(:params) { super().merge(experience_level: :novice) }
|
||||
|
||||
it 'sets the user’s experience level' do
|
||||
expect { subject }.to change { user.reload.experience_level }.from(nil).to('novice')
|
||||
end
|
||||
end
|
||||
|
||||
context 'when an unexpected experience level is sent' do
|
||||
let(:params) { super().merge(experience_level: :nonexistent) }
|
||||
|
||||
it 'raises an exception' do
|
||||
expect { subject }.to raise_error(ArgumentError, "'nonexistent' is not a valid experience_level")
|
||||
end
|
||||
end
|
||||
|
||||
context 'when "Learn GitLab" project exists' do
|
||||
let(:learn_gitlab_available?) { true }
|
||||
|
||||
before do
|
||||
allow_next_instance_of(LearnGitlab::Project) do |learn_gitlab|
|
||||
allow(learn_gitlab).to receive(:available?).and_return(learn_gitlab_available?)
|
||||
allow(learn_gitlab).to receive(:project).and_return(project)
|
||||
allow(learn_gitlab).to receive(:board).and_return(issues_board)
|
||||
allow(learn_gitlab).to receive(:label).and_return(double(id: 1))
|
||||
end
|
||||
end
|
||||
|
||||
context 'redirection' do
|
||||
context 'when namespace_path param is missing' do
|
||||
let(:params) { super().merge(namespace_path: nil) }
|
||||
|
||||
where(
|
||||
learn_gitlab_available?: [true, false]
|
||||
)
|
||||
|
||||
with_them do
|
||||
it { is_expected.to redirect_to('/') }
|
||||
end
|
||||
end
|
||||
|
||||
context 'when we have a namespace_path param' do
|
||||
using RSpec::Parameterized::TableSyntax
|
||||
|
||||
where(:learn_gitlab_available?, :path) do
|
||||
true | '/group-path/project-path/-/boards/123'
|
||||
false | '/group-path'
|
||||
end
|
||||
|
||||
with_them do
|
||||
it { is_expected.to redirect_to(path) }
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
context 'when novice' do
|
||||
let(:params) { super().merge(experience_level: :novice) }
|
||||
|
||||
it 'adds a BoardLabel' do
|
||||
expect_next(Boards::UpdateService).to receive(:execute)
|
||||
|
||||
subject
|
||||
end
|
||||
end
|
||||
|
||||
context 'when experienced' do
|
||||
let(:params) { super().merge(experience_level: :experienced) }
|
||||
|
||||
it 'does not add a BoardLabel' do
|
||||
expect(Boards::UpdateService).not_to receive(:new)
|
||||
|
||||
subject
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
context 'when no "Learn GitLab" project exists' do
|
||||
let(:params) { super().merge(experience_level: :novice) }
|
||||
|
||||
before do
|
||||
allow_next(LearnGitlab::Project).to receive(:available?).and_return(false)
|
||||
end
|
||||
|
||||
it 'does not add a BoardLabel' do
|
||||
expect(Boards::UpdateService).not_to receive(:new)
|
||||
|
||||
subject
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
context 'when user update fails' do
|
||||
before do
|
||||
allow_any_instance_of(User).to receive(:save).and_return(false)
|
||||
end
|
||||
|
||||
it { is_expected.to render_template(:show) }
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
@ -42,7 +42,7 @@ RSpec.describe 'Commit' do
|
|||
visit project_commit_path(project, commit)
|
||||
end
|
||||
|
||||
it "shows an adjusted count for changed files on this page" do
|
||||
it "shows an adjusted count for changed files on this page", :js do
|
||||
expect(page).to have_content("Showing 1 changed file")
|
||||
end
|
||||
|
||||
|
|
|
|||
|
|
@ -12,7 +12,7 @@ RSpec.describe 'User browses commits' do
|
|||
sign_in(user)
|
||||
end
|
||||
|
||||
it 'renders commit' do
|
||||
it 'renders commit', :js do
|
||||
visit project_commit_path(project, sample_commit.id)
|
||||
|
||||
expect(page).to have_content(sample_commit.message.gsub(/\s+/, ' '))
|
||||
|
|
@ -103,7 +103,7 @@ RSpec.describe 'User browses commits' do
|
|||
context 'when the blob does not exist' do
|
||||
let(:commit) { create(:commit, project: project) }
|
||||
|
||||
it 'renders successfully' do
|
||||
it 'renders successfully', :js do
|
||||
allow_next_instance_of(Gitlab::Diff::File) do |instance|
|
||||
allow(instance).to receive(:blob).and_return(nil)
|
||||
end
|
||||
|
|
@ -113,7 +113,9 @@ RSpec.describe 'User browses commits' do
|
|||
|
||||
visit(project_commit_path(project, commit))
|
||||
|
||||
expect(find('.diff-file-changes', visible: false)).to have_content('files/ruby/popen.rb')
|
||||
click_button '2 changed files'
|
||||
|
||||
expect(find('[data-testid="diff-stats-dropdown"]')).to have_content('files/ruby/popen.rb')
|
||||
end
|
||||
end
|
||||
|
||||
|
|
|
|||
|
|
@ -1,44 +0,0 @@
|
|||
# frozen_string_literal: true
|
||||
|
||||
require 'spec_helper'
|
||||
|
||||
RSpec.describe 'Experience level screen' do
|
||||
let_it_be(:user) { create(:user, :unconfirmed) }
|
||||
let_it_be(:group) { create(:group) }
|
||||
|
||||
before do
|
||||
group.add_owner(user)
|
||||
gitlab_sign_in(user)
|
||||
visit users_sign_up_experience_level_path(namespace_path: group.to_param)
|
||||
end
|
||||
|
||||
subject { page }
|
||||
|
||||
it 'shows the intro content' do
|
||||
is_expected.to have_content('Hello there')
|
||||
is_expected.to have_content('Welcome to the guided GitLab tour')
|
||||
is_expected.to have_content('What describes you best?')
|
||||
end
|
||||
|
||||
it 'shows the option for novice' do
|
||||
is_expected.to have_content('Novice')
|
||||
is_expected.to have_content('I’m not familiar with the basics of DevOps')
|
||||
is_expected.to have_content('Show me the basics')
|
||||
end
|
||||
|
||||
it 'shows the option for experienced' do
|
||||
is_expected.to have_content('Experienced')
|
||||
is_expected.to have_content('I’m familiar with the basics of DevOps')
|
||||
is_expected.to have_content('Show me advanced features')
|
||||
end
|
||||
|
||||
it 'does not display any flash messages' do
|
||||
is_expected.not_to have_selector('.flash-container')
|
||||
is_expected.not_to have_content("Please check your email (#{user.email}) to verify that you own this address and unlock the power of CI/CD")
|
||||
end
|
||||
|
||||
it 'does not include the footer links' do
|
||||
is_expected.not_to have_link('Help')
|
||||
is_expected.not_to have_link('About GitLab')
|
||||
end
|
||||
end
|
||||
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue