[docs] Update removing git dependencies
If --cached parameter is used, .gitmodules entry won't be removed. Instead, we need to manually remove .gitmodules entry. Change-Id: I33c2d5f609f16624686e1081678de4c0334cae4d Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5160447 Reviewed-by: Alexander Cooper <alcooper@chromium.org> Auto-Submit: Josip Sokcevic <sokcevic@chromium.org> Commit-Queue: Alexander Cooper <alcooper@chromium.org> Cr-Commit-Position: refs/heads/main@{#1242054}
This commit is contained in:

committed by
Chromium LUCI CQ

parent
3fea0effba
commit
3f9430e416
@ -195,21 +195,27 @@ section below).
|
||||
## Deleting dependencies
|
||||
|
||||
gclient doesn't provide a way to delete dependencies. You can delete dependency
|
||||
by manually editing DEPS file. If git submodules are used, you will also need to
|
||||
remove it from git:
|
||||
by manually editing DEPS file and running the following to update git
|
||||
submodules:
|
||||
|
||||
```
|
||||
git rm --cache {dependency}
|
||||
export DEPENDENCY={dependency}
|
||||
git rm --cached "$DEPENDENCY"
|
||||
git config -f .gitmodules --remove-section "submodule.$DEPENDENCY"
|
||||
git add .gitmodules
|
||||
```
|
||||
|
||||
or using the example from the previous section:
|
||||
Using the example from the previous section:
|
||||
|
||||
```
|
||||
git rm --cache third_party/boringssl/src
|
||||
export DEPENDENCY=third_party/boringssl/src
|
||||
git rm --cached "$DEPENDENCY"
|
||||
git config -f .gitmodules --remove-section "submodule.$DEPENDENCY"
|
||||
git add .gitmodules
|
||||
```
|
||||
|
||||
Once git-rm is executed, you can proceed with committing your change. You should
|
||||
see change in DEPS, .gitmodule and {dependency}.
|
||||
Once the commands are executed, you can proceed with committing your change. You
|
||||
should see change in DEPS, .gitmodule and {dependency}.
|
||||
|
||||
## Regenerating git submodules
|
||||
|
||||
|
Reference in New Issue
Block a user