aboutsummaryrefslogtreecommitdiffstats
path: root/org.eclipse.jgit.lfs/src/org/eclipse/jgit/lfs/internal
diff options
context:
space:
mode:
authorDavid Pursehouse <david.pursehouse@gmail.com>2018-03-05 10:53:12 +0900
committerDavid Pursehouse <david.pursehouse@gmail.com>2018-03-05 10:53:28 +0900
commit60b43c03e218a7c94257105820b790e8dbc0ab6f (patch)
tree1a20e432b793eba2c97357d3603d100f1ff48a22 /org.eclipse.jgit.lfs/src/org/eclipse/jgit/lfs/internal
parent28167853c120540db97a5c092646d0ed3316e1e8 (diff)
downloadjgit-60b43c03e218a7c94257105820b790e8dbc0ab6f.tar.gz
jgit-60b43c03e218a7c94257105820b790e8dbc0ab6f.zip
Add ConfigConstants.CONFIG_SECTION_LFS
DirCacheCheckout has a warning about non-localised string "lfs". Other classes use org.eclipse.jgit.lfs.lib.Constants but that is not visible to DirCacheCheckout. Add a new constant in ConfigConstants and use that in DirCacheCheckout. Replace existing uses of org.eclipse.jgit.lfs.lib.Constants.LFS with the new constant, except where it is referring to the folder name. Change-Id: I0f21b951babff9a2e579d68c4de0c62ee4bc23d4 Signed-off-by: David Pursehouse <david.pursehouse@gmail.com>
Diffstat (limited to 'org.eclipse.jgit.lfs/src/org/eclipse/jgit/lfs/internal')
-rw-r--r--org.eclipse.jgit.lfs/src/org/eclipse/jgit/lfs/internal/LfsConnectionFactory.java7
1 files changed, 4 insertions, 3 deletions
diff --git a/org.eclipse.jgit.lfs/src/org/eclipse/jgit/lfs/internal/LfsConnectionFactory.java b/org.eclipse.jgit.lfs/src/org/eclipse/jgit/lfs/internal/LfsConnectionFactory.java
index 3196e0730e..5d8268b73e 100644
--- a/org.eclipse.jgit.lfs/src/org/eclipse/jgit/lfs/internal/LfsConnectionFactory.java
+++ b/org.eclipse.jgit.lfs/src/org/eclipse/jgit/lfs/internal/LfsConnectionFactory.java
@@ -61,7 +61,6 @@ import org.eclipse.jgit.annotations.NonNull;
import org.eclipse.jgit.lfs.LfsPointer;
import org.eclipse.jgit.lfs.Protocol;
import org.eclipse.jgit.lfs.errors.LfsConfigInvalidException;
-import org.eclipse.jgit.lfs.lib.Constants;
import org.eclipse.jgit.lib.ConfigConstants;
import org.eclipse.jgit.lib.Repository;
import org.eclipse.jgit.lib.StoredConfig;
@@ -131,12 +130,14 @@ public class LfsConnectionFactory {
Map<String, String> additionalHeaders)
throws LfsConfigInvalidException {
StoredConfig config = db.getConfig();
- String lfsUrl = config.getString(Constants.LFS, null,
+ String lfsUrl = config.getString(ConfigConstants.CONFIG_SECTION_LFS,
+ null,
ConfigConstants.CONFIG_KEY_URL);
if (lfsUrl == null) {
String remoteUrl = null;
for (String remote : db.getRemoteNames()) {
- lfsUrl = config.getString(Constants.LFS, remote,
+ lfsUrl = config.getString(ConfigConstants.CONFIG_SECTION_LFS,
+ remote,
ConfigConstants.CONFIG_KEY_URL);
// This could be done better (more precise logic), but according
// to https://github.com/git-lfs/git-lfs/issues/1759 git-lfs