9 #include "../git/PathSpec.h" 24 unsigned match(
const std::filesystem::path &path)
const {
35 static std::optional<Pattern>
create(std::string pattern);
43 static constexpr
unsigned pattern_weight(std::string_view pattern);
static std::optional< Pattern > create(std::string pattern)
Build a (git) Pattern.
PathSpec is a representation of git pathspecs.
Definition: PathSpec.h:68
Holds git patterns and reports weights if matched.
Definition: Pattern.h:16
unsigned match(const std::filesystem::path &path) const
Match a path against the stored patterns.
Definition: Pattern.h:24
bool matchesPath(const std::string &path, uint32_t flags=GIT_PATHSPEC_DEFAULT) const noexcept
Return true if this PathSpec matches path.
Definition: PathSpec.h:80
Definition: Branches.h:15