Skip to content

Commit

Permalink
[dirmd] Use metadata mixins
Browse files Browse the repository at this point in the history
Use the new "mixins" feature in dirmd.
Derive mixins from file:// links in OWNERS files.

This CL is machine-generated, in two parts.

Part 1: use mixins.

1. Save current metadata to JSON files, in ORIGINAL and REDUCED forms.
   dirmd read -form original > ~/tmp/dirmd/original.json
   dirmd read -form reduced  > ~/tmp/dirmd/reduced.json
2. Run mixins.py.
   Source code: https://gist.github.com/nodirg/b59d3df338a72a8944f957c5b3a15e22

The script finds related directories, connected by file:// links
in OWNERS files. For those directories that have the same base
name, e.g.
  components/autofill
  chrome/android/java/src/org/chromium/chrome/browser/autofill
if importing the "parent" to the "child" reduces metadata, or adds
missing metadata, extract the common metadata to COMMON_METADATA
and import it in both directories.

Part2: deduplicate metadata.
Apply same instructions as in
https://chromium-review.googlesource.com/c/chromium/src/+/2795985/16

Bug: 1179786
Change-Id: I2e6378004ce433e02f1c9360b09eb72354083bf6
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2897943
Reviewed-by: John Abd-El-Malek <[email protected]>
Reviewed-by: Fred Mello <[email protected]>
Owners-Override: John Abd-El-Malek <[email protected]>
Commit-Queue: Nodir Turakulov <[email protected]>
Cr-Commit-Position: refs/heads/main@{#925648}
  • Loading branch information
nodirt authored and Chromium LUCI CQ committed Sep 28, 2021
1 parent 3a090ad commit de11715
Show file tree
Hide file tree
Showing 1,156 changed files with 1,828 additions and 2,156 deletions.
4 changes: 4 additions & 0 deletions apps/COMMON_METADATA
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
monorail {
component: "Platform>Apps"
}
team_email: "[email protected]"
5 changes: 1 addition & 4 deletions apps/DIR_METADATA
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,4 @@
# For the schema of this file, see Metadata message:
# https://source.chromium.org/chromium/infra/infra/+/main:go/src/infra/tools/dirmd/proto/dir_metadata.proto

monorail {
component: "Platform>Apps"
}
team_email: "[email protected]"
mixins: "//apps/COMMON_METADATA"
2 changes: 1 addition & 1 deletion ash/accessibility/DIR_METADATA
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
mixins: "//ui/accessibility/COMMON_METADATA"
monorail {
component: "OS>Accessibility"
}
team_email: "[email protected]"
4 changes: 1 addition & 3 deletions ash/app_list/views/assistant/DIR_METADATA
Original file line number Diff line number Diff line change
@@ -1,3 +1 @@
monorail {
component: "UI>Shell>Assistant"
}
mixins: "//chromeos/assistant/COMMON_METADATA"
4 changes: 1 addition & 3 deletions ash/assistant/DIR_METADATA
Original file line number Diff line number Diff line change
@@ -1,3 +1 @@
monorail {
component: "UI>Shell>Assistant"
}
mixins: "//chromeos/assistant/COMMON_METADATA"
1 change: 1 addition & 0 deletions ash/dbus/DIR_METADATA
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
mixins: "//chromeos/dbus/COMMON_METADATA"
3 changes: 3 additions & 0 deletions ash/keyboard/COMMON_METADATA
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
monorail {
component: "OS>Inputs"
}
4 changes: 1 addition & 3 deletions ash/keyboard/DIR_METADATA
Original file line number Diff line number Diff line change
@@ -1,3 +1 @@
monorail {
component: "OS>Inputs"
}
mixins: "//ash/keyboard/COMMON_METADATA"
1 change: 1 addition & 0 deletions ash/public/cpp/app_list/vector_icons/DIR_METADATA
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
mixins: "//components/vector_icons/COMMON_METADATA"
4 changes: 1 addition & 3 deletions ash/public/cpp/assistant/DIR_METADATA
Original file line number Diff line number Diff line change
@@ -1,3 +1 @@
monorail {
component: "UI>Shell>Assistant"
}
mixins: "//chromeos/assistant/COMMON_METADATA"
3 changes: 3 additions & 0 deletions ash/public/cpp/holding_space/COMMON_METADATA
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
monorail {
component: "UI>Shell>HoldingSpace"
}
4 changes: 1 addition & 3 deletions ash/public/cpp/holding_space/DIR_METADATA
Original file line number Diff line number Diff line change
@@ -1,3 +1 @@
monorail {
component: "UI>Shell>HoldingSpace"
}
mixins: "//ash/public/cpp/holding_space/COMMON_METADATA"
4 changes: 1 addition & 3 deletions ash/public/cpp/wallpaper/DIR_METADATA
Original file line number Diff line number Diff line change
@@ -1,3 +1 @@
monorail {
component: "OS>Systems>Wallpaper"
}
mixins: "//ash/wallpaper/COMMON_METADATA"
3 changes: 3 additions & 0 deletions ash/quick_pair/COMMON_METADATA
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
monorail: {
component: "OS>Systems>Multidevice>FastPair"
}
4 changes: 1 addition & 3 deletions ash/quick_pair/DIR_METADATA
Original file line number Diff line number Diff line change
@@ -1,3 +1 @@
monorail: {
component: "OS>Systems>Multidevice>FastPair"
}
mixins: "//ash/quick_pair/COMMON_METADATA"
1 change: 1 addition & 0 deletions ash/resources/vector_icons/DIR_METADATA
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
mixins: "//components/vector_icons/COMMON_METADATA"
4 changes: 1 addition & 3 deletions ash/services/quick_pair/DIR_METADATA
Original file line number Diff line number Diff line change
@@ -1,3 +1 @@
monorail: {
component: "OS>Systems>Multidevice>FastPair"
}
mixins: "//ash/quick_pair/COMMON_METADATA"
1 change: 1 addition & 0 deletions ash/shortcut_viewer/vector_icons/DIR_METADATA
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
mixins: "//components/vector_icons/COMMON_METADATA"
2 changes: 1 addition & 1 deletion ash/system/accessibility/DIR_METADATA
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
mixins: "//ui/accessibility/COMMON_METADATA"
monorail {
component: "OS>Accessibility"
}
team_email: "[email protected]"
1 change: 1 addition & 0 deletions ash/system/holding_space/DIR_METADATA
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
mixins: "//ash/public/cpp/holding_space/COMMON_METADATA"
1 change: 1 addition & 0 deletions ash/system/message_center/DIR_METADATA
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
mixins: "//ui/message_center/COMMON_METADATA"
monorail {
component: "UI>Shell>Notifications"
}
1 change: 1 addition & 0 deletions ash/system/phonehub/DIR_METADATA
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
mixins: "//chromeos/components/phonehub/COMMON_METADATA"
3 changes: 3 additions & 0 deletions ash/wallpaper/COMMON_METADATA
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
monorail {
component: "OS>Systems>Wallpaper"
}
4 changes: 1 addition & 3 deletions ash/wallpaper/DIR_METADATA
Original file line number Diff line number Diff line change
@@ -1,3 +1 @@
monorail {
component: "OS>Systems>Wallpaper"
}
mixins: "//ash/wallpaper/COMMON_METADATA"
4 changes: 1 addition & 3 deletions ash/webui/file_manager/DIR_METADATA
Original file line number Diff line number Diff line change
@@ -1,3 +1 @@
monorail {
component: "Platform>Apps>FileManager"
}
mixins: "//ui/file_manager/COMMON_METADATA"
1 change: 1 addition & 0 deletions base/android/COMMON_METADATA
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
os: ANDROID
2 changes: 1 addition & 1 deletion base/android/DIR_METADATA
Original file line number Diff line number Diff line change
@@ -1 +1 @@
os: ANDROID
mixins: "//base/android/COMMON_METADATA"
5 changes: 1 addition & 4 deletions base/fuchsia/DIR_METADATA
Original file line number Diff line number Diff line change
@@ -1,5 +1,2 @@
monorail {
component: "Fuchsia"
}
team_email: "[email protected]"
mixins: "//build/fuchsia/COMMON_METADATA"
os: FUCHSIA
3 changes: 3 additions & 0 deletions base/metrics/COMMON_METADATA
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
monorail {
component: "Internals>Metrics"
}
4 changes: 1 addition & 3 deletions base/metrics/DIR_METADATA
Original file line number Diff line number Diff line change
@@ -1,3 +1 @@
monorail {
component: "Internals>Metrics"
}
mixins: "//base/metrics/COMMON_METADATA"
1 change: 1 addition & 0 deletions base/test/android/DIR_METADATA
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
mixins: "//base/android/COMMON_METADATA"
monorail {
component: "Test>Android"
}
4 changes: 1 addition & 3 deletions base/test/metrics/DIR_METADATA
Original file line number Diff line number Diff line change
@@ -1,3 +1 @@
monorail {
component: "Internals>Metrics"
}
mixins: "//base/metrics/COMMON_METADATA"
1 change: 1 addition & 0 deletions build/android/COMMON_METADATA
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
os: ANDROID
2 changes: 1 addition & 1 deletion build/android/DIR_METADATA
Original file line number Diff line number Diff line change
@@ -1 +1 @@
os: ANDROID
mixins: "//build/android/COMMON_METADATA"
1 change: 1 addition & 0 deletions build/config/android/DIR_METADATA
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
mixins: "//build/android/COMMON_METADATA"
6 changes: 1 addition & 5 deletions build/config/fuchsia/DIR_METADATA
Original file line number Diff line number Diff line change
@@ -1,7 +1,3 @@
monorail {
component: "Fuchsia"
}

team_email: "[email protected]"
mixins: "//build/fuchsia/COMMON_METADATA"

os: FUCHSIA
5 changes: 5 additions & 0 deletions build/fuchsia/COMMON_METADATA
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
monorail {
component: "Fuchsia"
}

team_email: "[email protected]"
5 changes: 1 addition & 4 deletions build/fuchsia/DIR_METADATA
Original file line number Diff line number Diff line change
@@ -1,5 +1,2 @@
monorail {
component: "Fuchsia"
}
mixins: "//build/fuchsia/COMMON_METADATA"

team_email: "[email protected]"
1 change: 1 addition & 0 deletions build/toolchain/android/DIR_METADATA
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
mixins: "//build/android/COMMON_METADATA"
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
monorail {
component: "UI>Browser>Mobile"
}
team_email: "[email protected]"
os: ANDROID
6 changes: 1 addition & 5 deletions chrome/android/DIR_METADATA
Original file line number Diff line number Diff line change
@@ -1,5 +1 @@
monorail {
component: "UI>Browser>Mobile"
}
team_email: "[email protected]"
os: ANDROID
mixins: "//chrome/android/COMMON_METADATA"
1 change: 1 addition & 0 deletions chrome/android/features/autofill_assistant/DIR_METADATA
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
mixins: "//components/autofill_assistant/COMMON_METADATA"
5 changes: 1 addition & 4 deletions chrome/android/feed/DIR_METADATA
Original file line number Diff line number Diff line change
@@ -1,4 +1 @@
monorail {
component: "UI>Browser>ContentSuggestions>Feed"
}
team_email: "[email protected]"
mixins: "//components/feed/COMMON_METADATA"
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
monorail {
component: "UI>Browser>Mobile>Settings"
}
team_email: "[email protected]"
Original file line number Diff line number Diff line change
@@ -1,4 +1 @@
monorail {
component: "UI>Browser>Mobile>Settings"
}
team_email: "[email protected]"
mixins: "//chrome/android/java/src/org/chromium/chrome/browser/about_settings/COMMON_METADATA"
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
monorail {
component: "UI>Browser>Accessibility"
}
team_email: "[email protected]"
Original file line number Diff line number Diff line change
@@ -1,4 +1 @@
monorail {
component: "UI>Browser>Accessibility"
}
team_email: "[email protected]"
mixins: "//chrome/android/java/src/org/chromium/chrome/browser/accessibility/COMMON_METADATA"
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
monorail {
component: "UI>Browser>Mobile>TabSwitcher"
}
team_email: "[email protected]"
Original file line number Diff line number Diff line change
@@ -1,4 +1 @@
monorail {
component: "UI>Browser>Mobile>TabSwitcher"
}
team_email: "[email protected]"
mixins: "//chrome/android/java/src/org/chromium/chrome/browser/accessibility_tab_switcher/COMMON_METADATA"
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
mixins: "//chrome/browser/ui/android/appmenu/COMMON_METADATA"
Original file line number Diff line number Diff line change
@@ -1,4 +1 @@
monorail {
component: "Internals>Flags"
}
team_email: "[email protected]"
mixins: "//chrome/browser/flags/COMMON_METADATA"
Original file line number Diff line number Diff line change
@@ -1,4 +1,2 @@
monorail {
component: "Upboarding>VideoTutorials"
}
mixins: "//chrome/browser/video_tutorials/COMMON_METADATA"
team_email: "[email protected]"
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
monorail {
component: "UI>Browser>Autofill>UI"
}
Original file line number Diff line number Diff line change
@@ -1,3 +1,2 @@
monorail {
component: "UI>Browser>Autofill>UI"
}
mixins: "//components/autofill/COMMON_METADATA"
mixins: "//chrome/android/java/src/org/chromium/chrome/browser/autofill/COMMON_METADATA"
Original file line number Diff line number Diff line change
@@ -1,3 +1 @@
monorail {
component: "UI>Browser>Autofill>Assistant"
}
mixins: "//components/autofill_assistant/COMMON_METADATA"
Original file line number Diff line number Diff line change
@@ -1,4 +1 @@
monorail {
component: "Blink>BackgroundSync"
}
team_email: "[email protected]"
mixins: "//components/background_sync/COMMON_METADATA"
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
mixins: "//components/background_task_scheduler/COMMON_METADATA"
Original file line number Diff line number Diff line change
@@ -1,3 +1 @@
monorail {
component: "UI>Browser>WebAppInstalls"
}
mixins: "//chrome/browser/banners/COMMON_METADATA"
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
monorail {
component: "UI>Browser>Bookmarks"
}
team_email: "[email protected]"
Original file line number Diff line number Diff line change
@@ -1,4 +1 @@
monorail {
component: "UI>Browser>Bookmarks"
}
team_email: "[email protected]"
mixins: "//chrome/android/java/src/org/chromium/chrome/browser/bookmarks/COMMON_METADATA"
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
monorail {
component: "UI>Browser>Mobile>CustomTabs"
}
Original file line number Diff line number Diff line change
@@ -1,3 +1 @@
monorail {
component: "UI>Browser>Mobile>CustomTabs"
}
mixins: "//chrome/android/java/src/org/chromium/chrome/browser/browserservices/COMMON_METADATA"
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
monorail {
component: "Privacy"
}
Original file line number Diff line number Diff line change
@@ -1,3 +1 @@
monorail {
component: "Privacy"
}
mixins: "//chrome/android/java/src/org/chromium/chrome/browser/browsing_data/COMMON_METADATA"
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
mixins: "//components/component_updater/COMMON_METADATA"
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
monorail {
component: "UI>Browser>Mobile>CompositedUI"
}
team_email: "[email protected]"
Original file line number Diff line number Diff line change
@@ -1,4 +1 @@
monorail {
component: "UI>Browser>Mobile>CompositedUI"
}
team_email: "[email protected]"
mixins: "//chrome/android/java/src/org/chromium/chrome/browser/compositor/COMMON_METADATA"
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
monorail {
component: "UI>Browser>Search>ContextualSearch"
}
team_email: "[email protected]"
Original file line number Diff line number Diff line change
@@ -1,4 +1 @@
monorail {
component: "UI>Browser>Search>ContextualSearch"
}
team_email: "[email protected]"
mixins: "//chrome/android/java/src/org/chromium/chrome/browser/compositor/bottombar/COMMON_METADATA"
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
mixins: "//components/content_capture/COMMON_METADATA"
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
monorail {
component: "UI>Browser>Mobile>ContextMenu"
}
team_email: "[email protected]"
Original file line number Diff line number Diff line change
@@ -1,4 +1 @@
monorail {
component: "UI>Browser>Mobile>ContextMenu"
}
team_email: "[email protected]"
mixins: "//chrome/android/java/src/org/chromium/chrome/browser/contextmenu/COMMON_METADATA"
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
monorail {
component: "UI>Browser>Joy"
}
team_email: "[email protected]"
Original file line number Diff line number Diff line change
@@ -1,4 +1 @@
monorail {
component: "UI>Browser>Joy"
}
team_email: "[email protected]"
mixins: "//chrome/android/java/src/org/chromium/chrome/browser/cryptids/COMMON_METADATA"
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
monorail {
component: "UI>Browser>Mobile>CustomTabs"
}
team_email: "[email protected]"
Original file line number Diff line number Diff line change
@@ -1,4 +1 @@
monorail {
component: "UI>Browser>Mobile>CustomTabs"
}
team_email: "[email protected]"
mixins: "//chrome/android/java/src/org/chromium/chrome/browser/customtabs/COMMON_METADATA"
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
monorail {
component: "Blink>Layout"
}
Original file line number Diff line number Diff line change
@@ -1,3 +1 @@
monorail {
component: "Blink>Layout"
}
mixins: "//chrome/android/java/src/org/chromium/chrome/browser/display_cutout/COMMON_METADATA"
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
monorail {
component: "UI>Browser>ReaderMode"
}
team_email: "[email protected]"
Original file line number Diff line number Diff line change
@@ -1,4 +1 @@
monorail {
component: "UI>Browser>ReaderMode"
}
team_email: "[email protected]"
mixins: "//chrome/android/java/src/org/chromium/chrome/browser/dom_distiller/COMMON_METADATA"
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
mixins: "//chrome/browser/android/explore_sites/COMMON_METADATA"
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
team_email: "[email protected]"
Original file line number Diff line number Diff line change
@@ -1 +1 @@
team_email: "[email protected]"
mixins: "//chrome/android/java/src/org/chromium/chrome/browser/gesturenav/COMMON_METADATA"
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
monorail {
component: "UI>Browser>Infobars"
}
Original file line number Diff line number Diff line change
@@ -1,3 +1 @@
monorail {
component: "UI>Browser>Infobars"
}
mixins: "//chrome/android/java/src/org/chromium/chrome/browser/infobar/COMMON_METADATA"
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
monorail {
component: "Platform>Apps>AppLauncher>Install"
}
Loading

0 comments on commit de11715

Please sign in to comment.