Ver Fonte

[cipd] Add git-credential-luci (reland)

This can be used for OAuth to Gerrit (in lieu of gitcookies).

Originally landed
https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/5620638

Reverted due to interfering with git fetch

https://ci.chromium.org/ui/p/infra-internal/builders/cron/build%20recipe%20roller/b8745385521046617057/infra

Fixed by excluding git-credential-luci from recipe bundles

Bug: b/335483238
Change-Id: I9a0887b32596be122509de0ec1c238088e73bb49
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/5627937
Reviewed-by: Scott Lee <ddoman@chromium.org>
Commit-Queue: Allen Li <ayatane@chromium.org>
Allen Li há 1 ano atrás
pai
commit
02b791b756
5 ficheiros alterados com 92 adições e 5 exclusões
  1. 6 5
      .gitattributes
  2. 3 0
      cipd_manifest.txt
  3. 60 0
      cipd_manifest.versions
  4. 14 0
      git-credential-luci
  5. 9 0
      git-credential-luci.bat

+ 6 - 5
.gitattributes

@@ -20,6 +20,7 @@
 /fetch                        recipes
 /gclient                      recipes
 /git*                         recipes
+/git-credential-luci          -recipes
 /gn                           recipes
 /ninja*                       recipes
 /pylint*                      recipes
@@ -32,10 +33,10 @@
 /cipd_manifest* recipes
 
 # Symlinks
-/cbuildbot      recipes
-/cros*          recipes
+/cbuildbot recipes
+/cros*     recipes
 
-/lib/* recipes
+/lib/*     recipes
 
 # Metadata validation package, without its tests.
 /metadata/**       recipes
@@ -43,9 +44,9 @@
 
 # TODO: There are some really junky dependencies in here that we should probably
 # move to vpython/cipd.
-/third_party/**                     recipes
+/third_party/**     recipes
 
-/win_toolchain/** recipes
+/win_toolchain/**   recipes
 
 /fetch_configs/*.py recipes
 

+ 3 - 0
cipd_manifest.txt

@@ -48,6 +48,9 @@ infra/tools/prpc/${platform} git_revision:bd3a982ae62b4820b71414b2340e86019a1fbd
 # LUCI authentication command line tool
 infra/tools/luci-auth/${platform} git_revision:02ffe6e2b222aa1f56776b8e5385f49687451bb2
 
+# LUCI Git credential helper
+infra/tools/luci/git-credential-luci/${platform} git_revision:d41024b9e474be209a7975b2d57b175a84095d12
+
 # LUCI Buildbucket CLI
 infra/tools/bb/${platform} git_revision:b1ef34e3c86269b1261ccbc039ff2cfe3baaa961
 

+ 60 - 0
cipd_manifest.versions

@@ -245,6 +245,66 @@ infra/tools/luci-auth/windows-arm64
 	git_revision:02ffe6e2b222aa1f56776b8e5385f49687451bb2
 	LctndLGHwJNf5ISBA-IIzZClyN2SOd-bDH8eo2KLDCwC
 
+infra/tools/luci/git-credential-luci/linux-386
+	git_revision:d41024b9e474be209a7975b2d57b175a84095d12
+	S6QIVeaPXKgsc1U4JciZZzsw1-Pfp_cCP0i4zbxxjIAC
+
+infra/tools/luci/git-credential-luci/linux-amd64
+	git_revision:d41024b9e474be209a7975b2d57b175a84095d12
+	tOZX3cHK2_cILsJ7RWIyOEyyQkpACbVyQ-4nopfMPbQC
+
+infra/tools/luci/git-credential-luci/linux-arm64
+	git_revision:d41024b9e474be209a7975b2d57b175a84095d12
+	X_CW5S_Faf45qv5xT3v0cr1qBWWwUPN-585mSTvKNMMC
+
+infra/tools/luci/git-credential-luci/linux-armv6l
+	git_revision:d41024b9e474be209a7975b2d57b175a84095d12
+	DPwPpKyIXSQGEANQixBLiNFZ0wnj0Oe36DWSs09fuVEC
+
+infra/tools/luci/git-credential-luci/linux-mips64
+	git_revision:d41024b9e474be209a7975b2d57b175a84095d12
+	tq7BSmjlkXSvSgaIvrD3H_bTT39_AtI7lMoDeLXoU3UC
+
+infra/tools/luci/git-credential-luci/linux-mips64le
+	git_revision:d41024b9e474be209a7975b2d57b175a84095d12
+	Hl9uMsH3jICJKLXx3REaz69L4gy-_SYN5htIDAP7tKYC
+
+infra/tools/luci/git-credential-luci/linux-mipsle
+	git_revision:d41024b9e474be209a7975b2d57b175a84095d12
+	2ZOemf48Pdouxzho2Cr9_gq_Q_kTGjk8KTzAdERqmGcC
+
+infra/tools/luci/git-credential-luci/linux-ppc64
+	git_revision:d41024b9e474be209a7975b2d57b175a84095d12
+	jorHWijFrUEJzXnAo74hBfw6emDgTGbhXOYYk0SYrjwC
+
+infra/tools/luci/git-credential-luci/linux-ppc64le
+	git_revision:d41024b9e474be209a7975b2d57b175a84095d12
+	LPqHNKkwZShoVmohj1ROzC8W8rCWhwmIGVi7VmKehuAC
+
+infra/tools/luci/git-credential-luci/linux-riscv64
+	git_revision:d41024b9e474be209a7975b2d57b175a84095d12
+	Hw6k9RIiX4ZqyCo0YozXCyBWYDdp8VVOGP-o97dJNn8C
+
+infra/tools/luci/git-credential-luci/linux-s390x
+	git_revision:d41024b9e474be209a7975b2d57b175a84095d12
+	fu04xl2Lht1dUioJEiHkCge6I1BkIQ0GnaAfptYI1IwC
+
+infra/tools/luci/git-credential-luci/mac-amd64
+	git_revision:d41024b9e474be209a7975b2d57b175a84095d12
+	Nlyk3PX4XgcHHW0i8wUsSaAwx87hkGDoVsJX97uUMNwC
+
+infra/tools/luci/git-credential-luci/mac-arm64
+	git_revision:d41024b9e474be209a7975b2d57b175a84095d12
+	pNZXdU4hDGvri-nvl_5MJlku5SeqTWvUdBU_9mDZpjoC
+
+infra/tools/luci/git-credential-luci/windows-amd64
+	git_revision:d41024b9e474be209a7975b2d57b175a84095d12
+	82mhQ1-O3Zobh-C5rygCRpqlX7KFLpLjYX7aUz0MPGYC
+
+infra/tools/luci/git-credential-luci/windows-arm64
+	git_revision:d41024b9e474be209a7975b2d57b175a84095d12
+	JcxrohcfOU_OBxkGI1Fr6XU_tQFptmPMg1lHiMwrwScC
+
 infra/tools/luci/led/linux-386
 	git_revision:037d7079cf3faced3842e597c9dfcc7475b2ddca
 	ge-5N3T2kBzlysOhp2Y3b7DTRiU0N4GqI_Q3ELf_MUYC

+ 14 - 0
git-credential-luci

@@ -0,0 +1,14 @@
+#!/usr/bin/env bash
+
+# Copyright 2024 The Chromium Authors. All rights reserved.
+# Use of this source code is governed by a BSD-style license that can be
+# found in the LICENSE file.
+
+# See revert instructions in cipd_manifest.txt
+
+MYPATH=$(dirname "${BASH_SOURCE[0]}")
+
+source "$MYPATH/cipd_bin_setup.sh"
+cipd_bin_setup &> /dev/null
+
+exec "$MYPATH/.cipd_bin/git-credential-luci" "$@"

+ 9 - 0
git-credential-luci.bat

@@ -0,0 +1,9 @@
+@echo off
+:: Copyright 2024 The Chromium Authors. All rights reserved.
+:: Use of this source code is governed by a BSD-style license that can be
+:: found in the LICENSE file.
+
+:: See revert instructions in cipd_manifest.txt
+
+call "%~dp0\cipd_bin_setup.bat" > nul 2>&1
+"%~dp0\.cipd_bin\git-credential-luci.exe" %*