Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
李少辉-开发者
gitlab-foss
提交
4584816f
G
gitlab-foss
项目概览
李少辉-开发者
/
gitlab-foss
通知
15
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
G
gitlab-foss
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
前往新版Gitcode,体验更适合开发者的 AI 搜索 >>
提交
4584816f
编写于
6月 22, 2020
作者:
G
GitLab Bot
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Add latest changes from gitlab-org/gitlab@master
上级
4c344d3b
变更
11
隐藏空白更改
内联
并排
Showing
11 changed file
with
24 addition
and
30 deletion
+24
-30
.rubocop_todo.yml
.rubocop_todo.yml
+0
-15
app/validators/addressable_url_validator.rb
app/validators/addressable_url_validator.rb
+3
-3
config/initializers/action_dispatch_journey_formatter.rb
config/initializers/action_dispatch_journey_formatter.rb
+2
-2
doc/development/telemetry/usage_ping.md
doc/development/telemetry/usage_ping.md
+2
-1
doc/user/project/static_site_editor/index.md
doc/user/project/static_site_editor/index.md
+7
-0
lib/gitlab/config/entry/configurable.rb
lib/gitlab/config/entry/configurable.rb
+3
-1
lib/gitlab/config/entry/node.rb
lib/gitlab/config/entry/node.rb
+1
-1
lib/gitlab/discussions_diff/file_collection.rb
lib/gitlab/discussions_diff/file_collection.rb
+2
-2
lib/gitlab/error_tracking.rb
lib/gitlab/error_tracking.rb
+1
-2
lib/rspec_flaky/flaky_examples_collection.rb
lib/rspec_flaky/flaky_examples_collection.rb
+1
-1
spec/lib/gitlab/database_importers/common_metrics/prometheus_metric_spec.rb
...tabase_importers/common_metrics/prometheus_metric_spec.rb
+2
-2
未找到文件。
.rubocop_todo.yml
浏览文件 @
4584816f
...
...
@@ -569,21 +569,6 @@ Style/HashTransformKeys:
-
'
lib/banzai/filter/commit_trailers_filter.rb'
-
'
lib/gitlab/analytics/cycle_analytics/stage_events.rb'
# Offense count: 10
# Cop supports --auto-correct.
Style/HashTransformValues
:
Exclude
:
-
'
app/validators/addressable_url_validator.rb'
-
'
config/initializers/action_dispatch_journey_formatter.rb'
-
'
ee/app/helpers/compliance_management/compliance_framework/project_settings_helper.rb'
-
'
ee/app/services/packages/nuget/metadata_extraction_service.rb'
-
'
lib/gitlab/config/entry/configurable.rb'
-
'
lib/gitlab/config/entry/node.rb'
-
'
lib/gitlab/discussions_diff/file_collection.rb'
-
'
lib/gitlab/error_tracking.rb'
-
'
lib/rspec_flaky/flaky_examples_collection.rb'
-
'
spec/lib/gitlab/database_importers/common_metrics/prometheus_metric_spec.rb'
# Offense count: 31
# Configuration parameters: AllowIfModifier.
Style/IfInsideElse
:
...
...
app/validators/addressable_url_validator.rb
浏览文件 @
4584816f
...
...
@@ -95,9 +95,9 @@ class AddressableUrlValidator < ActiveModel::EachValidator
end
def
current_options
options
.
map
do
|
option
,
value
|
[
option
,
value
.
is_a?
(
Proc
)
?
value
.
call
(
record
)
:
value
]
end
.
to_h
options
.
transform_values
do
|
value
|
value
.
is_a?
(
Proc
)
?
value
.
call
(
record
)
:
value
end
end
def
blocker_args
...
...
config/initializers/action_dispatch_journey_formatter.rb
浏览文件 @
4584816f
...
...
@@ -9,8 +9,8 @@ module ActionDispatch
module
Path
class
Pattern
def
requirements_for_missing_keys_check
@requirements_for_missing_keys_check
||=
requirements
.
each_with_object
({})
do
|
(
key
,
regex
),
hash
|
hash
[
key
]
=
/\A
#{
regex
}
\Z/
@requirements_for_missing_keys_check
||=
requirements
.
transform_values
do
|
regex
|
/\A
#{
regex
}
\Z/
end
end
end
...
...
doc/development/telemetry/usage_ping.md
浏览文件 @
4584816f
...
...
@@ -461,7 +461,8 @@ appear to be associated to any of the services running, since they all appear to
|
`releases`
|
`counts`
|
`release`
| | | Unique release tags |
|
`remote_mirrors`
|
`counts`
| | | | |
|
`requirements_created`
|
`counts`
| | | | |
|
`snippets`
|
`counts`
| | | | |
|
`snippets`
|
`counts`
| 'create' | | | |
|
`snippets`
|
`counts_monthly`
| 'create' | | | |
|
`suggestions`
|
`counts`
| | | | |
|
`todos`
|
`counts`
| | | | |
|
`uploads`
|
`counts`
| | | | |
...
...
doc/user/project/static_site_editor/index.md
浏览文件 @
4584816f
...
...
@@ -7,6 +7,8 @@ description: "The static site editor enables users to edit content on static web
> - [Introduced](https://gitlab.com/gitlab-org/gitlab/-/merge_requests/28758) in GitLab 12.10.
> - WYSIWYG editor [introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/214559) in GitLab 13.0.
> - Support for adding images through the WYSIWYG editor [introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/216640) in GitLab 13.1.
> - Markdown front matter hidden on the WYSIWYG editor [introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/216834) in GitLab 13.1.
DANGER:
**Danger:**
In GitLab 13.0, we
[
introduced breaking changes
](
https://gitlab.com/gitlab-org/gitlab/-/issues/213282
)
...
...
@@ -78,6 +80,11 @@ Anyone satisfying the [requirements](#requirements) will be able to edit the
content of the pages without prior knowledge of Git nor of your site's
codebase.
NOTE:
**Note:**
From GitLab 13.1 onwards, the YAML front matter of Markdown files is hidden on the
WYSIWYG editor to avoid unintended changes. To edit it, use the Markdown editing mode, the regular
GitLab file editor, or the Web IDE.
### Use the Static Site Editor to edit your content
For instance, suppose you are a recently hired technical writer at a large
...
...
lib/gitlab/config/entry/configurable.rb
浏览文件 @
4584816f
...
...
@@ -62,7 +62,9 @@ module Gitlab
class_methods
do
def
nodes
Hash
[(
@nodes
||
{}).
map
{
|
key
,
factory
|
[
key
,
factory
.
dup
]
}]
return
{}
unless
@nodes
@nodes
.
transform_values
(
&
:dup
)
end
def
reserved_node_names
...
...
lib/gitlab/config/entry/node.rb
浏览文件 @
4584816f
...
...
@@ -68,7 +68,7 @@ module Gitlab
value
.
specified?
&&
value
.
relevant?
end
Hash
[
meaningful
.
map
{
|
key
,
entry
|
[
key
,
entry
.
value
]
}]
meaningful
.
transform_values
{
|
entry
|
entry
.
value
}
end
end
...
...
lib/gitlab/discussions_diff/file_collection.rb
浏览文件 @
4584816f
...
...
@@ -70,8 +70,8 @@ module Gitlab
#
# Returns a Hash with { id => [Array of Gitlab::Diff::line], ...]
def
highlighted_lines_by_ids
(
ids
)
diff_files_indexed_by_id
.
slice
(
*
ids
).
each_with_object
({})
do
|
(
id
,
file
),
hash
|
hash
[
id
]
=
file
.
highlighted_diff_lines
.
map
(
&
:to_hash
)
diff_files_indexed_by_id
.
slice
(
*
ids
).
transform_values
do
|
file
|
file
.
highlighted_diff_lines
.
map
(
&
:to_hash
)
end
end
end
...
...
lib/gitlab/error_tracking.rb
浏览文件 @
4584816f
...
...
@@ -173,8 +173,7 @@ module Gitlab
.
connection
.
schema_cache
.
instance_variable_get
(
:@columns_hash
)
.
map
{
|
k
,
v
|
[
k
,
v
.
map
(
&
:first
)]
}
.
to_h
.
transform_values
{
|
v
|
v
.
map
(
&
:first
)
}
event
.
extra
.
merge!
(
columns_hash
)
end
...
...
lib/rspec_flaky/flaky_examples_collection.rb
浏览文件 @
4584816f
...
...
@@ -23,7 +23,7 @@ module RspecFlaky
end
def
to_h
Hash
[
map
{
|
uid
,
example
|
[
uid
,
example
.
to_h
]
}]
.
deep_symbolize_keys
transform_values
{
|
example
|
example
.
to_h
}
.
deep_symbolize_keys
end
def
-
(
other
)
...
...
spec/lib/gitlab/database_importers/common_metrics/prometheus_metric_spec.rb
浏览文件 @
4584816f
...
...
@@ -8,8 +8,8 @@ describe Gitlab::DatabaseImporters::CommonMetrics::PrometheusMetric do
end
it
'.group_titles equals ::PrometheusMetric'
do
existing_group_titles
=
::
PrometheusMetricEnums
.
group_details
.
each_with_object
({})
do
|
(
key
,
value
),
memo
|
memo
[
key
]
=
value
[
:group_title
]
existing_group_titles
=
::
PrometheusMetricEnums
.
group_details
.
transform_values
do
|
value
|
value
[
:group_title
]
end
expect
(
Gitlab
::
DatabaseImporters
::
CommonMetrics
::
PrometheusMetricEnums
.
group_titles
).
to
eq
(
existing_group_titles
)
end
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录