File tree Expand file tree Collapse file tree 1 file changed +10
-1
lines changed
Expand file tree Collapse file tree 1 file changed +10
-1
lines changed Original file line number Diff line number Diff line change @@ -435,7 +435,16 @@ struct GitInputScheme : InputScheme
435435 //
436436 // See: https://discourse.nixos.org/t/57783 and #9708
437437 //
438- repoInfo.url = repoInfo.isLocal ? std::filesystem::absolute (url.path ).string () : url.to_string ();
438+ if (repoInfo.isLocal ) {
439+ if (!isAbsolute (url.path )) {
440+ warn (
441+ " Fetching Git repository '%s', which uses a path relative to the current directory. "
442+ " This is not supported and will stop working in a future release." ,
443+ url);
444+ }
445+ repoInfo.url = std::filesystem::absolute (url.path ).string ();
446+ } else
447+ repoInfo.url = url.to_string ();
439448
440449 // If this is a local directory and no ref or revision is
441450 // given, then allow the use of an unclean working tree.
You can’t perform that action at this time.
0 commit comments