| 173 | } |
| 174 | |
| 175 | std::string rebasePath(const std::string &Path, const std::string &OrgBase, |
| 176 | const std::string &NewBase) { |
| 177 | auto LeafPath = getRelativePath(Path, OrgBase); |
| 178 | assert(!LeafPath.empty() && "Invalid base path"); |
| 179 | return fs::path(NewBase) / LeafPath; |
| 180 | } |
| 181 | |
| 182 | } // namespace util |
| 183 |