◐ Shell
reader mode source ↗
Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
File filter
Conversations
Jump to
Diff view
Apply and reload
Show whitespace
Diff view
Apply and reload
8 changes: 6 additions & 2 deletions git/config.py
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@
CONFIG_LEVELS: ConfigLevels_Tup = ("system", "user", "global", "repository")
"""The configuration level of a configuration file."""

CONDITIONAL_INCLUDE_REGEXP = re.compile(r"(?<=includeIf )\"(gitdir|gitdir/i|onbranch):(.+)\"")
"""Section pattern to detect conditional includes.

See: https://git-scm.com/docs/git-config#_conditional_includes
Expand Down Expand Up @@ -590,7 +590,11 @@ def _included_paths(self) -> List[Tuple[str, str]]:

if fnmatch.fnmatchcase(branch_name, value):
paths += self.items(section)

return paths

def read(self) -> None: # type: ignore[override]
Expand Down
Loading
Toggle all file notes Toggle all file annotations