mirror of
https://github.com/privatevoid-net/nix-super.git
synced 2024-11-30 09:36:15 +02:00
cmatch -> smatch
This commit is contained in:
parent
454e3a541a
commit
15b888c9a5
1 changed files with 4 additions and 4 deletions
|
@ -88,8 +88,8 @@ FlakeRef::FlakeRef(const std::string & uri_, bool allowRelative)
|
||||||
return true;
|
return true;
|
||||||
};
|
};
|
||||||
|
|
||||||
std::cmatch match;
|
std::smatch match;
|
||||||
if (std::regex_match(uri.c_str(), match, flakeRegex)) {
|
if (std::regex_match(uri, match, flakeRegex)) {
|
||||||
IsId d;
|
IsId d;
|
||||||
d.id = match[1];
|
d.id = match[1];
|
||||||
if (match[2].matched)
|
if (match[2].matched)
|
||||||
|
@ -102,7 +102,7 @@ FlakeRef::FlakeRef(const std::string & uri_, bool allowRelative)
|
||||||
data = d;
|
data = d;
|
||||||
}
|
}
|
||||||
|
|
||||||
else if (std::regex_match(uri.c_str(), match, githubRegex)) {
|
else if (std::regex_match(uri, match, githubRegex)) {
|
||||||
IsGitHub d;
|
IsGitHub d;
|
||||||
d.owner = match[1];
|
d.owner = match[1];
|
||||||
d.repo = match[2];
|
d.repo = match[2];
|
||||||
|
@ -120,7 +120,7 @@ FlakeRef::FlakeRef(const std::string & uri_, bool allowRelative)
|
||||||
data = d;
|
data = d;
|
||||||
}
|
}
|
||||||
|
|
||||||
else if (std::regex_match(uri.c_str(), match, uriRegex)) {
|
else if (std::regex_match(uri, match, uriRegex)) {
|
||||||
auto & scheme = match[2];
|
auto & scheme = match[2];
|
||||||
if (scheme == "git" ||
|
if (scheme == "git" ||
|
||||||
scheme == "git+http" ||
|
scheme == "git+http" ||
|
||||||
|
|
Loading…
Reference in a new issue