forked from haskell/cabal
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
VCS: Don't run submodule commands unless necessary
Running `git submodule` commands is harmless but clutters up the logs, making the tests difficult to debug when run in verbose-mode. Doesn't seem to impact performance much. I measured a ~1.5% speedup with this code, which is well within error margins. See: https://github.com/haskell/cabal/pull/7625/files#r709617991
- Loading branch information
Showing
4 changed files
with
60 additions
and
25 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
--- | ||
synopsis: "Don't run submodule commands unless necessary" | ||
packages: [cabal-install] | ||
prs: 10590 | ||
--- | ||
|
||
When `cabal` clones a Git repo for a `source-repository-package` listed in a | ||
`cabal.project`, it will run various commands to check out the correct | ||
revision, initialize submodules if they're present, and so on. | ||
|
||
Now, `cabal` will avoid running `git submodule` commands unless the cloned | ||
repository contains a `.gitmodules` file. This will declutter `cabal`'s debug | ||
output by running fewer commands. | ||
|