aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/main/java/com/google/devtools/build/lib/rules/repository/LocalRepositoryFunction.java
diff options
context:
space:
mode:
authorGravatar tomlu <tomlu@google.com>2018-01-19 09:28:06 -0800
committerGravatar Copybara-Service <copybara-piper@google.com>2018-01-19 09:30:16 -0800
commit8cc5dcf34cf5156db78ccf5f936ca3c8b893c36f (patch)
tree5d10eb07b1c4bcd43c36ac4dc02c31a18a2fe3d0 /src/main/java/com/google/devtools/build/lib/rules/repository/LocalRepositoryFunction.java
parent8608df20d98873d1aecf2d6f08836d0b56f826fa (diff)
Rename relativePath -> rootRelativePath in Root and friends.
This makes it clearer that the path fragments in question are relative *to the root*. Confusingly, when the root is absolute, the root relative fragment is also absolute. This makes it a tiny bit clearer that the path fragment may be absolute. PiperOrigin-RevId: 182544893
Diffstat (limited to 'src/main/java/com/google/devtools/build/lib/rules/repository/LocalRepositoryFunction.java')
-rw-r--r--src/main/java/com/google/devtools/build/lib/rules/repository/LocalRepositoryFunction.java4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/main/java/com/google/devtools/build/lib/rules/repository/LocalRepositoryFunction.java b/src/main/java/com/google/devtools/build/lib/rules/repository/LocalRepositoryFunction.java
index 5b8f088745..a335d9db8b 100644
--- a/src/main/java/com/google/devtools/build/lib/rules/repository/LocalRepositoryFunction.java
+++ b/src/main/java/com/google/devtools/build/lib/rules/repository/LocalRepositoryFunction.java
@@ -96,7 +96,9 @@ public class LocalRepositoryFunction extends RepositoryFunction {
RootedPath workspaceRootedFile =
RootedPath.toRootedPath(
directory.getRoot(),
- directory.getRelativePath().getRelative(BuildFileName.WORKSPACE.getFilenameFragment()));
+ directory
+ .getRootRelativePath()
+ .getRelative(BuildFileName.WORKSPACE.getFilenameFragment()));
SkyKey workspaceFileKey = FileValue.key(workspaceRootedFile);
FileValue value;