diff options
author | James Moger <james.moger@gitblit.com> | 2013-03-29 11:14:42 -0400 |
---|---|---|
committer | James Moger <james.moger@gitblit.com> | 2013-03-29 11:14:42 -0400 |
commit | ea4769096f9f303964107e2c3d95c63857588fc5 (patch) | |
tree | 18ba66381f04eee38f5eb9b3868edf48a9013f1b /src/main/java | |
parent | f5654729757eedefc1c656ac4be764b6a19ada2e (diff) | |
download | gitblit-ea4769096f9f303964107e2c3d95c63857588fc5.tar.gz gitblit-ea4769096f9f303964107e2c3d95c63857588fc5.zip |
Fixed regression with individually symlinked repositories (issue 217)
Diffstat (limited to 'src/main/java')
-rw-r--r-- | src/main/java/com/gitblit/GitBlit.java | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/main/java/com/gitblit/GitBlit.java b/src/main/java/com/gitblit/GitBlit.java index 7c6a5350..65dc559c 100644 --- a/src/main/java/com/gitblit/GitBlit.java +++ b/src/main/java/com/gitblit/GitBlit.java @@ -1656,6 +1656,11 @@ public class GitBlit implements ServletContextListener { } else {
model.name = com.gitblit.utils.FileUtils.getRelativePath(basePath, r.getDirectory().getParentFile());
}
+ if (StringUtils.isEmpty(model.name)) {
+ // Repository is NOT located relative to the base folder because it
+ // is symlinked. Use the provided repository name.
+ model.name = repositoryName;
+ }
model.hasCommits = JGitUtils.hasCommits(r);
model.lastChange = JGitUtils.getLastChange(r);
model.projectPath = StringUtils.getFirstPathElement(repositoryName);
|