Allen Li
d3d038869a
git_auth: Handle conflicting stale local config (reland)
...
As we prefer configuring the global config, it's possible to leave
stale local config behind if the user is swapping between emails.
Originally:
https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/7213753
Fixed to skip clearing local config when not inside a repo (as that errors).
Bug: 466343784
Change-Id: I8b34d24ba3966c66aeebaf11bd0368dfb4b0da28
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/7265721
Reviewed-by: Gavin Mak <gavinmak@google.com >
Commit-Queue: Allen Li <ayatane@chromium.org >
2025-12-16 17:19:31 -08:00
Yiwei Zhang
e0a877ed8f
Revert "git_auth: Handle conflicting stale local config"
...
This reverts commit e96cff71c9 .
Reason for revert: causing https://issues.chromium.org/466343784
Original change's description:
> git_auth: Handle conflicting stale local config
>
> As we prefer configuring the global config, it's possible to leave
> stale local config behind if the user is swapping between emails.
>
> Change-Id: I86e2cda33a90b603e52d525fcb564fb0a5a68eab
> Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/7213753
> Reviewed-by: Gavin Mak <gavinmak@google.com >
> Commit-Queue: Allen Li <ayatane@chromium.org >
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Change-Id: Iec8ce86a6d17b26e5cc3940a38c6510ad3f855be
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/7231141
Bot-Commit: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com >
Auto-Submit: Yiwei Zhang <yiwzhang@google.com >
Commit-Queue: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com >
2025-12-05 09:56:59 -08:00
Allen Li
e96cff71c9
git_auth: Handle conflicting stale local config
...
As we prefer configuring the global config, it's possible to leave
stale local config behind if the user is swapping between emails.
Change-Id: I86e2cda33a90b603e52d525fcb564fb0a5a68eab
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/7213753
Reviewed-by: Gavin Mak <gavinmak@google.com >
Commit-Queue: Allen Li <ayatane@chromium.org >
2025-12-04 15:15:29 -08:00
Allen Li
85116f1710
git_auth: Add messaging about setting global config
...
Change-Id: I4b95e88f1d7a1e20c9e44258a4276b07fc0769fb
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/7213752
Reviewed-by: Gavin Mak <gavinmak@google.com >
Commit-Queue: Allen Li <ayatane@chromium.org >
2025-12-03 18:26:42 -08:00
Allen Li
9238ab49b6
git_auth: Inline single use helpers
...
Change-Id: I5ca184b59a3d592bb4121e8f4a9ec2e54665ef57
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/7173366
Reviewed-by: Gavin Mak <gavinmak@google.com >
Commit-Queue: Allen Li <ayatane@chromium.org >
2025-12-02 17:12:59 -08:00
Allen Li
1acf6d271e
git_auth: Configure both variations of Gerrit hosts
...
ChromeOS sometimes uses -review URLs, so we should support both
Bug: 419182970
Change-Id: I9a3836f5544a8422ccda8ded6e9d88d5a10edda2
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/7173365
Commit-Queue: Allen Li <ayatane@chromium.org >
Reviewed-by: Gavin Mak <gavinmak@google.com >
2025-12-02 16:35:21 -08:00
Allen Li
375fb27dca
git_auth: Organize helpers
...
Group URL returning helpers together
Bug: 419182970
Change-Id: Icec51bec8b0ce808d70c1eff7131933d1419719e
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/7173363
Reviewed-by: Gavin Mak <gavinmak@google.com >
Commit-Queue: Allen Li <ayatane@chromium.org >
2025-11-19 16:13:46 -08:00
Allen Li
a158a297ce
git_auth: Add _set_url_rewrites helper
...
Add an intermediate helper on the path to supporting -review URLs.
Bug: 419182970
Change-Id: I792ccc0c4dca3be5db625aca4a48e7edad1e9ba0
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/7164719
Reviewed-by: Gavin Mak <gavinmak@google.com >
Commit-Queue: Allen Li <ayatane@chromium.org >
2025-11-19 14:50:03 -08:00
Allen Li
b8f203014f
git_auth: Add some docstrings
...
Change-Id: I6bb0299cadfd92304a112e2d90a926c6006d1a46
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/7164717
Reviewed-by: Gavin Mak <gavinmak@google.com >
Auto-Submit: Allen Li <ayatane@chromium.org >
Commit-Queue: Gavin Mak <gavinmak@google.com >
2025-11-18 11:41:59 -08:00
Allen Li
dac161882f
git_auth: Simplify global flag handling
...
The "We will pretend to be running outside of a Gerrit repository" is
confusing since --global is generally the recommended mode now. Also
simplifies the code.
Change-Id: Ia698f5ba4cbfce50c7754a4c7d86ca791e89d183
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/7153131
Reviewed-by: Gavin Mak <gavinmak@google.com >
Commit-Queue: Allen Li <ayatane@chromium.org >
2025-11-17 13:01:21 -08:00
Allen Li
8132b22e9f
git_auth: Handle netrc files
...
Bug: 454827122
Change-Id: I3d6d28bf9332b47a2c802b08bbeb35c118753c44
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/7122358
Commit-Queue: Allen Li <ayatane@chromium.org >
Reviewed-by: Gavin Mak <gavinmak@google.com >
2025-11-05 15:52:36 -08:00
Allen Li
da1bb1b99d
git_auth: Delete unused ConfigChanger
...
All usages have been removed a while ago.
Bug: 446999231
Change-Id: I40de9de7dc027c22652dd45ad75bbba3377bd923
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/7082062
Reviewed-by: Gavin Mak <gavinmak@google.com >
Commit-Queue: Allen Li <ayatane@chromium.org >
2025-10-28 14:00:42 -07:00
Allen Li
1c23880345
git_auth: Delete Configure functions
...
Has been unused for a while, remove it now
Bug: 446999231
Change-Id: I54bcac7effe0c97d8ec3daa833338a8301a4b1fb
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6981221
Commit-Queue: Allen Li <ayatane@chromium.org >
Reviewed-by: Gavin Mak <gavinmak@google.com >
2025-09-24 17:42:51 -07:00
Allen Li
06da8b2a8f
git_cl: Delete usages of AutoConfigure
...
Has been no-op for a while, remove it now
Bug: 446999231
Change-Id: I9f4e5b9cbd6a5cb8e84fba2f0ebb949b2a88d9ff
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6981220
Reviewed-by: Gavin Mak <gavinmak@google.com >
Commit-Queue: Allen Li <ayatane@chromium.org >
2025-09-24 16:06:55 -07:00
Allen Li
838e4c6aa7
[git_cl] Remove the auto cleanup from disabled new auth
...
This is in preparation for removing the old auto config code. New
auth has been rolled out stably for a long time now, and in any case
the auto config/cleanup code isn't super reliable (hence why we're
removing it).
We remove this final callsite before deleting all of the relevant
code, and leave a message of assistance in case anyone needs it.
Bug: 446999231
Change-Id: Ia13e5d75a89a4ddfb178ee9e4fe2090596493218
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6976601
Commit-Queue: Allen Li <ayatane@chromium.org >
Reviewed-by: Gavin Mak <gavinmak@google.com >
2025-09-23 19:52:53 -07:00
Allen Li
eddc72dce5
[git_auth] Disable auto configure logic
...
Trying to configure users' git config automatically has been more
trouble than it's worth. All users should be on new auth now (with
the help of the manual wizard), so disable the auto logic (and then
delete it later) so we don't get bitten by the auto logic
unintentionally interacting in a bad way later.
Bug: 430668572
Change-Id: Ia1f92d1bea834eb3be1887ea9c54d2e1a70ae33c
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6821484
Commit-Queue: Allen Li <ayatane@chromium.org >
Reviewed-by: Gavin Mak <gavinmak@google.com >
2025-08-07 14:33:44 -07:00
Allen Li
342cd35666
[git_auth] Add useHttpPath config for Gerrit auth
...
This is needed to pass the repo path to the credential helper, so we
can distinguish repos that need ReAuth.
Change-Id: I5aa72d6ec0421dcbff610f48f34129b8962050f7
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6822598
Reviewed-by: Gavin Mak <gavinmak@google.com >
Commit-Queue: Allen Li <ayatane@chromium.org >
2025-08-07 14:07:49 -07:00
Joey Scarr
57dfc366b7
Revert "[git_auth] Configure common -review hosts also"
...
This reverts commit 39e269dabf .
Reason for revert: Breaks git cl upload via SSO
Bug: 421831933
Original change's description:
> [git_auth] Configure common -review hosts also
>
> Seems like ChromeOS workflows with repo force these URLs. While the
> repo instructions technically tell users to set this up separately,
> config them here too so I don't get bug reports.
>
> Bug: 421831933
> Change-Id: Ie33c678de3a6d2dadd6663ad6e0e97e9086d6129
> Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6614517
> Reviewed-by: Gavin Mak <gavinmak@google.com >
> Commit-Queue: Allen Li <ayatane@chromium.org >
Bug: 421831933
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Change-Id: I76a981ff50bc1b9e18c82223e23d891b89917924
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6615841
Auto-Submit: Joey Scarr <jsca@google.com >
Owners-Override: Joey Scarr <jsca@google.com >
Commit-Queue: Joey Scarr <jsca@google.com >
Reviewed-by: Fumitoshi Ukai <ukai@google.com >
Bot-Commit: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com >
2025-06-02 21:55:46 -07:00
Allen Li
39e269dabf
[git_auth] Configure common -review hosts also
...
Seems like ChromeOS workflows with repo force these URLs. While the
repo instructions technically tell users to set this up separately,
config them here too so I don't get bug reports.
Bug: 421831933
Change-Id: Ie33c678de3a6d2dadd6663ad6e0e97e9086d6129
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6614517
Reviewed-by: Gavin Mak <gavinmak@google.com >
Commit-Queue: Allen Li <ayatane@chromium.org >
2025-06-02 15:18:53 -07:00
Mike Frysinger
2b62f95de3
git_auth: fix ~/ handling in http.cookiefile
...
Change-Id: Ifa9505477fa1e1e717e1a499f5200f8840d7be50
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6597961
Reviewed-by: Gavin Mak <gavinmak@google.com >
Commit-Queue: Mike Frysinger <vapier@chromium.org >
2025-05-28 12:46:21 -07:00
Allen Li
f55de362c1
[git_auth] Check and fix auth on GCE
...
Bug: 410713357
Change-Id: I6d39641451d78c192321b77477a5e0f741715f85
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6485110
Reviewed-by: Gavin Mak <gavinmak@google.com >
Commit-Queue: Allen Li <ayatane@chromium.org >
2025-04-24 14:21:42 -07:00
Allen Li
1fb0e39429
[git_auth] Add short blurb with manual setup instructions
...
Might be useful for some folks, try adding this.
Bug: 410825515
Change-Id: I367298b8276758c25167aa520556fb63a175127f
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6459926
Reviewed-by: Yiwei Zhang <yiwzhang@google.com >
Reviewed-by: Gavin Mak <gavinmak@google.com >
Commit-Queue: Allen Li <ayatane@chromium.org >
2025-04-16 14:28:14 -07:00
Allen Li
5d5475cdee
[git_auth] Minor wording consistency fix
...
Make it consistent with the other line that uses "yet"
Change-Id: I6cae354b61ac673bb4d93a878daf01cebbf67a0b
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6459922
Reviewed-by: Gavin Mak <gavinmak@google.com >
Commit-Queue: Allen Li <ayatane@chromium.org >
Reviewed-by: Yiwei Zhang <yiwzhang@google.com >
2025-04-15 15:15:03 -07:00
Allen Li
d28539d200
[git_auth] Move gitcookies to free backup name
...
Bug: 410576093
Change-Id: Ib2d9db97f4e4e1e8cfe1914ba7ffb881f9e16bbf
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6453918
Reviewed-by: Yiwei Zhang <yiwzhang@google.com >
Commit-Queue: Yiwei Zhang <yiwzhang@google.com >
Reviewed-by: Gavin Mak <gavinmak@google.com >
2025-04-15 14:54:46 -07:00
Allen Li
9d75b76ca5
[git_auth] Clarify which email to use
...
Change-Id: Ic17568c3b6fd35772b3c7d5c9db8e62e207fb7fc
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6456193
Commit-Queue: Allen Li <ayatane@chromium.org >
Reviewed-by: Gavin Mak <gavinmak@google.com >
Reviewed-by: Yiwei Zhang <yiwzhang@google.com >
2025-04-15 14:44:33 -07:00
Allen Li
c92c5fbe99
[git_auth] Always configure chrome-internal
...
Most users who access this have SSO, but there are some people with,
e.g., read access without SSO.
So we may as well configure this always I guess, even if it's
nonfunctional for many people since they have no permission to any
repos on chrome-internal.
Change-Id: Ia560a64e7771f1438fb1527389a310bbbe951477
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6456192
Reviewed-by: Yiwei Zhang <yiwzhang@google.com >
Reviewed-by: Gavin Mak <gavinmak@google.com >
Commit-Queue: Allen Li <ayatane@chromium.org >
2025-04-15 14:08:44 -07:00
Allen Li
0aa5b44d94
[git_auth] Hint users to run with --global
...
Some users just run creds-check which doesn't fix submodules.
Bug: 408501013
Change-Id: Iddb19e922aff8cb265638588595403ac193ead52
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6449740
Commit-Queue: Allen Li <ayatane@chromium.org >
Reviewed-by: Dirk Pranke <dpranke@google.com >
Reviewed-by: Yiwei Zhang <yiwzhang@google.com >
2025-04-14 16:09:40 -07:00
Allen Li
0a7f853f9d
[git_auth] Split repo configuring into standalone method
...
Refactoring to enable running this logic recursively on submodules.
Change-Id: I3515d1659e1b619d262a62be91f0fe835f6df0d1
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6448584
Commit-Queue: Allen Li <ayatane@chromium.org >
Reviewed-by: Yiwei Zhang <yiwzhang@google.com >
2025-04-14 14:59:48 -07:00
Allen Li
f3a8e0a209
[git_auth] Add _run_gerrit_host_configuration helper
...
Refactoring to improve readability
Change-Id: I159565840f7c869d47a70beb22000d01c6279a1a
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6448580
Reviewed-by: Gavin Mak <gavinmak@google.com >
Reviewed-by: Yiwei Zhang <yiwzhang@google.com >
Commit-Queue: Allen Li <ayatane@chromium.org >
2025-04-14 14:39:46 -07:00
Allen Li
3b66d05bd8
[git_auth] Inject Changelist dependency into ConfigWizard
...
Otherwise it creates a dependency cycle. This is needed if we want to
recurse into submodules. Maybe this should be refactored more, but
this should be an improvement for now.
Change-Id: I4641e9ce1952bba81f717acbeefd59dd687d87ec
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6448579
Reviewed-by: Yiwei Zhang <yiwzhang@google.com >
Commit-Queue: Allen Li <ayatane@chromium.org >
2025-04-14 13:33:58 -07:00
Allen Li
68e296445e
[git_auth] Pause before configuring common hosts
...
The config dumps a lot of text, so pause here. Probably improves UX a
bit.
Change-Id: I9890f9286abe28ecc3e6f05b6d0dde94c5bc9710
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6442237
Commit-Queue: Allen Li <ayatane@chromium.org >
Reviewed-by: Dirk Pranke <dpranke@google.com >
Reviewed-by: Gavin Mak <gavinmak@google.com >
2025-04-08 16:37:29 -07:00
Allen Li
f5b53c0e98
[git_cl] Add --global to creds-check
...
The UX of cd'ing to a non-Gerrit repo to setup common repo auth is not
good. Also people don't read.
Bug: 408501013
Change-Id: Ia31914cf8672d0b5a6033de11c928140fd34a95c
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6442235
Reviewed-by: Gavin Mak <gavinmak@google.com >
Commit-Queue: Allen Li <ayatane@chromium.org >
2025-04-08 15:16:09 -07:00
Allen Li
07d24776f2
[git_auth] Emphasize success
...
People assume the tool has failed and keep trying to re-run it when it
says to run git credential-luci login.
Bug: 408501013
Change-Id: Id1f671bacfdc19d4614ff03cfa69bfd484ad741b
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6441970
Reviewed-by: Yiwei Zhang <yiwzhang@google.com >
Commit-Queue: Allen Li <ayatane@chromium.org >
2025-04-08 14:15:24 -07:00
Allen Li
c65a345b10
[git_auth] Improve login instruction wording
...
Quick minor improvement based on user feedback.
Bug: 408225524
Change-Id: I51029dd97cb64a4b35ccd385d2af95ba1200bd25
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6440070
Reviewed-by: Gavin Mak <gavinmak@google.com >
Commit-Queue: Allen Li <ayatane@chromium.org >
2025-04-07 16:04:15 -07:00
Allen Li
3f00993a55
[git_cl] Explain SSO check
...
Clarify why SSO is needed for the check, even if the account may not
need SSO.
Bug: 408243787
Change-Id: If855eec2dbc414a112db3469b5cc73b3f5846651
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6431248
Reviewed-by: Yiwei Zhang <yiwzhang@google.com >
Reviewed-by: Gavin Mak <gavinmak@google.com >
Commit-Queue: Allen Li <ayatane@chromium.org >
2025-04-04 15:33:18 -07:00
Allen Li
321b0e6b99
[git_auth] Add guard against bad URLs
...
In particular, when we enable new auth by default, one of the tests
that uses gclient to clone a local directory fails.
Bug: 404613530
Change-Id: I1bd41da2a3aba6f92cc3d5d9c75ab4d8fc293f22
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6426441
Commit-Queue: Allen Li <ayatane@chromium.org >
Reviewed-by: Yiwei Zhang <yiwzhang@google.com >
2025-04-02 15:45:19 -07:00
Allen Li
e32bcc7be0
[git_auth] Print empty line after all read input
...
Small UX improvement
Bug: 404613530
Change-Id: Ie1cb79279a41cd80f1992e2e18107d4a15e16edb
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6418884
Reviewed-by: Yiwei Zhang <yiwzhang@google.com >
Commit-Queue: Allen Li <ayatane@chromium.org >
2025-04-01 15:34:35 -07:00
Allen Li
a2c6f107c3
[git_auth] Move config wizard to creds-check
...
Bug: b/404613530
Change-Id: Ie0b8fd675b66739a129d5eeeda895473a8a49eeb
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6368999
Commit-Queue: Allen Li <ayatane@chromium.org >
Reviewed-by: Josip Sokcevic <sokcevic@chromium.org >
2025-03-19 14:01:37 -07:00
Allen Li
428ceb6428
[git_auth] Add extra info about OAuth setup
...
Change-Id: I145d18dbddee27b8655005c789191b3c524f0710
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6367722
Commit-Queue: Allen Li <ayatane@chromium.org >
Reviewed-by: Josip Sokcevic <sokcevic@chromium.org >
2025-03-18 15:32:05 -07:00
Allen Li
a0d13c9549
[git_auth] Use pathless URL for cred helper
...
The credential helper rules should not have a path, while the URL
rewrite rules should.
Reland of I79b52ab4af62367363617b2a9afa03a67f5ea0b9
Bug: b/401338175
Bug: b/403635929
Change-Id: Ib89d9e855ca5eba29cc67f8846bb7ca0cb3622ab
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6363080
Reviewed-by: Josip Sokcevic <sokcevic@chromium.org >
Commit-Queue: Allen Li <ayatane@chromium.org >
2025-03-18 14:38:56 -07:00
Allen Li
8fecc592a2
Add auth config wizard
...
Make this available for testing first.
This should be functionally roughly analogous with the current auto
configuration logic, and it prints all actions it performs so it
should be pretty safe to play with, even if it hypothetically
misbehaves.
Bug: b/401338175
Change-Id: I803c7e167e355ec8cca1f5959099138c2fee305e
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6334614
Reviewed-by: Josip Sokcevic <sokcevic@chromium.org >
Commit-Queue: Allen Li <ayatane@chromium.org >
2025-03-14 17:00:13 -07:00
Josip Sokcevic
948edc4382
Revert "[git_auth] Use pathless URL for cred helper"
...
This reverts commit ce47e785fa .
Reason for revert: fatal: --local can only be used inside a git
repository.
Original change's description:
> [git_auth] Use pathless URL for cred helper
>
> The credential helper rules should not have a path, while the URL
> rewrite rules should.
>
> Bug: b/401338175
> Change-Id: I79b52ab4af62367363617b2a9afa03a67f5ea0b9
> Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6345631
> Commit-Queue: Allen Li <ayatane@chromium.org >
> Reviewed-by: Josip Sokcevic <sokcevic@chromium.org >
Bug: b/401338175
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Change-Id: Ifa887eeb7a7049665570e865431b41ac18649b90
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6357165
Bot-Commit: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com >
Auto-Submit: Josip Sokcevic <sokcevic@chromium.org >
Commit-Queue: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com >
2025-03-14 15:06:10 -07:00
Allen Li
ce47e785fa
[git_auth] Use pathless URL for cred helper
...
The credential helper rules should not have a path, while the URL
rewrite rules should.
Bug: b/401338175
Change-Id: I79b52ab4af62367363617b2a9afa03a67f5ea0b9
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6345631
Commit-Queue: Allen Li <ayatane@chromium.org >
Reviewed-by: Josip Sokcevic <sokcevic@chromium.org >
2025-03-14 13:42:33 -07:00
Allen Li
0445e00a08
[git_auth] Add _url_shortname helper
...
Breaking out independent chunks from a larger CL
Bug: b/401338175
Change-Id: I0b439596fb613355cb33b4b1d2a0481489d7c0c3
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6345630
Reviewed-by: Josip Sokcevic <sokcevic@chromium.org >
Commit-Queue: Allen Li <ayatane@chromium.org >
2025-03-11 20:00:09 -07:00
Josip Sokcevic
f61e11c19f
roll_dep_test: fix tests
...
This partially reverts commit 1221440015 .
Change-Id: Ib2e9d41b3871004376a952e643e13a7e67eb750e
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6340427
Commit-Queue: Yiwei Zhang <yiwzhang@google.com >
Reviewed-by: Yiwei Zhang <yiwzhang@google.com >
Reviewed-by: Allen Li <ayatane@chromium.org >
2025-03-10 15:57:39 -07:00
Allen Li
877b1e3cbd
[auth] Hide global SSO rewrite in local repo
...
If the user uses SSO (and thus has SSO rewrite rules) for their global
config, a repo which locally uses an email that doesn't use SSO needs
an override.
Bug: b/390219533
Change-Id: I639dae4c1a45bbd2c17180855c22260979b0dbc2
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6177780
Reviewed-by: Josip Sokcevic <sokcevic@chromium.org >
Commit-Queue: Allen Li <ayatane@chromium.org >
2025-01-21 13:59:20 -08:00
Allen Li
522f5a4bd1
gerrit_util: Use git-credential-luci instead of luci-auth
...
git-credential-luci is very similar to luci-auth, except that it is
expressly for git/Gerrit. Therefore, it hard codes the scopes needed
for git/Gerrit. It's also a separate binary, which makes it more
convenient for us to configure it for ReAuth later.
Bug: b/382341041
Change-Id: I7de56d3922adac7eb4671849eb6e30be310d4de7
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6073043
Reviewed-by: Josip Sokcevic <sokcevic@chromium.org >
Commit-Queue: Allen Li <ayatane@chromium.org >
2024-12-06 01:39:13 +00:00
Allen Li
4b94130034
[gerrit_util] Add fallback if missing Gerrit account
...
Bug: b/366261039
Change-Id: I7d22c4f03ad9bd837190dee7a511af3437a30434
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/5869050
Reviewed-by: Josip Sokcevic <sokcevic@chromium.org >
Commit-Queue: Allen Li <ayatane@chromium.org >
2024-09-18 21:57:33 +00:00
Allen Li
58e0e19462
[git_auth] Remove old option cleanup
...
Change-Id: I426199d05613397a74aba87ad8dcbd67a0175ee7
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/5869051
Reviewed-by: Josip Sokcevic <sokcevic@chromium.org >
Commit-Queue: Allen Li <ayatane@chromium.org >
2024-09-17 21:52:13 +00:00
Allen Li
a603aded9a
[gclient_scm] Add new auth stack setup to gclient
...
Bug: b/356935829
Change-Id: Ie917f142c3fddba398a5351d685a7b131b298a76
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/5762791
Commit-Queue: Allen Li <ayatane@chromium.org >
Reviewed-by: Josip Sokcevic <sokcevic@chromium.org >
2024-08-07 22:11:56 +00:00