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

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2023-06-20 13:43:29 +0300
committerGitLab Bot <gitlab-bot@gitlab.com>2023-06-20 13:43:29 +0300
commit3b1af5cc7ed2666ff18b718ce5d30fa5a2756674 (patch)
tree3bc4a40e0ee51ec27eabf917c537033c0c5b14d4 /tooling
parent9bba14be3f2c211bf79e15769cd9b77bc73a13bc (diff)
Add latest changes from gitlab-org/gitlab@16-1-stable-eev16.1.0-rc42
Diffstat (limited to 'tooling')
-rw-r--r--tooling/danger/analytics_instrumentation.rb2
-rw-r--r--tooling/danger/database.rb20
-rw-r--r--tooling/danger/project_helper.rb1
-rw-r--r--tooling/docs/deprecation_handling.rb2
4 files changed, 23 insertions, 2 deletions
diff --git a/tooling/danger/analytics_instrumentation.rb b/tooling/danger/analytics_instrumentation.rb
index ce5ee55e3ee..767ae8dfb4c 100644
--- a/tooling/danger/analytics_instrumentation.rb
+++ b/tooling/danger/analytics_instrumentation.rb
@@ -8,7 +8,7 @@ module Tooling
APPROVED_LABEL = 'analytics instrumentation::approved'
REVIEW_LABEL = 'analytics instrumentation::review pending'
CHANGED_FILES_MESSAGE = <<~MSG
- For the following files, a review from the [Data team and Analytics Instrumentation team](https://gitlab.com/groups/gitlab-org/analytics-section/product-intelligence/engineers/-/group_members?with_inherited_permissions=exclude) is recommended
+ For the following files, a review from the [Data team and Analytics Instrumentation team](https://gitlab.com/groups/gitlab-org/analytics-section/analytics-instrumentation/engineers/-/group_members?with_inherited_permissions=exclude) is recommended
Please check the ~"analytics instrumentation" [Service Ping guide](https://docs.gitlab.com/ee/development/service_ping/) or the [Snowplow guide](https://docs.gitlab.com/ee/development/snowplow/).
For MR review guidelines, see the [Service Ping review guidelines](https://docs.gitlab.com/ee/development/service_ping/review_guidelines.html) or the [Snowplow review guidelines](https://docs.gitlab.com/ee/development/snowplow/review_guidelines.html).
diff --git a/tooling/danger/database.rb b/tooling/danger/database.rb
new file mode 100644
index 00000000000..4cfac7c4af4
--- /dev/null
+++ b/tooling/danger/database.rb
@@ -0,0 +1,20 @@
+# frozen_string_literal: true
+
+module Tooling
+ module Danger
+ module Database
+ TIMESTAMP_MATCHER = /(?<timestamp>\d{14})/
+ MIGRATION_MATCHER = %r{\A(ee/)?db/(geo/)?(post_)?migrate/}
+
+ def find_migration_files_before(file_names, cutoff)
+ migrations = file_names.select { |f| f.match?(MIGRATION_MATCHER) }
+ migrations.select do |migration|
+ next unless match = TIMESTAMP_MATCHER.match(migration)
+
+ timestamp = Date.parse(match[:timestamp])
+ timestamp < cutoff
+ end
+ end
+ end
+ end
+end
diff --git a/tooling/danger/project_helper.rb b/tooling/danger/project_helper.rb
index 5b5b998e3ea..9ab6c5fa32e 100644
--- a/tooling/danger/project_helper.rb
+++ b/tooling/danger/project_helper.rb
@@ -115,6 +115,7 @@ module Tooling
%r{\A((ee|jh)/)?scripts/(lib/)?glfm/.*\.rb} => [:backend],
%r{\A((ee|jh)/)?scripts/(lib/)?glfm/.*\.js} => [:frontend],
+ %r{\A((ee|jh)/)?scripts/remote_development/.*} => [:remote_development],
%r{\A((ee|jh)/)?scripts/.*\.rb} => [:backend, :tooling],
%r{\A((ee|jh)/)?scripts/.*\.js} => [:frontend, :tooling],
%r{\A((ee|jh)/)?scripts/} => :tooling,
diff --git a/tooling/docs/deprecation_handling.rb b/tooling/docs/deprecation_handling.rb
index 5996a0c89c1..320f5df0b07 100644
--- a/tooling/docs/deprecation_handling.rb
+++ b/tooling/docs/deprecation_handling.rb
@@ -17,7 +17,7 @@ module Docs
end
entries = source_file_paths.flat_map do |file|
- YAML.load_file(file)
+ YAML.safe_load_file(file, permitted_classes: [Date])
end
entries = entries.sort_by { |d| d["title"] }