Browse Source

Silence warnings for non-externalized strings

These warnings were missed to address in a0048208 which introduced them.

Change-Id: Ia2d15fdce72c10378d020682b80fe7fc548c0d4c
Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
stable-5.5
Matthias Sohn 5 years ago
parent
commit
cd9422f239
  1. 6
      org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/pack/PackWriter.java
  2. 24
      org.eclipse.jgit/src/org/eclipse/jgit/transport/UploadPack.java

6
org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/pack/PackWriter.java

@ -654,7 +654,7 @@ public class PackWriter implements AutoCloseable {
}
/**
* @param config configuration related to packfile URIs
* @param config configuration related to packfile URIs
* @since 5.5
*/
public void setPackfileUriConfig(PackfileUriConfig config) {
@ -1223,7 +1223,7 @@ public class PackWriter implements AutoCloseable {
CachedPackUriProvider p = packfileUriConfig.cachedPackUriProvider;
PacketLineOut o = packfileUriConfig.pckOut;
o.writeString("packfile-uris\n");
o.writeString("packfile-uris\n"); //$NON-NLS-1$
for (CachedPack pack : cachedPacks) {
CachedPackUriProvider.PackInfo packInfo = p.getInfo(
pack, packfileUriConfig.protocolsSupported);
@ -1235,7 +1235,7 @@ public class PackWriter implements AutoCloseable {
}
}
packfileUriConfig.pckOut.writeDelim();
packfileUriConfig.pckOut.writeString("packfile\n");
packfileUriConfig.pckOut.writeString("packfile\n"); //$NON-NLS-1$
} else {
unwrittenCachedPacks = cachedPacks;
}

24
org.eclipse.jgit/src/org/eclipse/jgit/transport/UploadPack.java

@ -1285,20 +1285,22 @@ public class UploadPack {
.format(JGitText.get().unknownTransportCommand, command));
}
@SuppressWarnings("nls")
private List<String> getV2CapabilityAdvertisement() {
ArrayList<String> caps = new ArrayList<>();
caps.add("version 2"); //$NON-NLS-1$
caps.add("version 2");
caps.add(COMMAND_LS_REFS);
boolean advertiseRefInWant = transferConfig.isAllowRefInWant() &&
db.getConfig().getBoolean("uploadpack", null, //$NON-NLS-1$
"advertiserefinwant", true); //$NON-NLS-1$
caps.add(
COMMAND_FETCH + '=' +
(transferConfig.isAllowFilter() ? OPTION_FILTER + ' ' : "") + //$NON-NLS-1$
(advertiseRefInWant ? CAPABILITY_REF_IN_WANT + ' ' : "") + //$NON-NLS-1$
(transferConfig.isAllowSidebandAll() ? OPTION_SIDEBAND_ALL + ' ' : "") + //$NON-NLS-1$
(cachedPackUriProvider != null ? "packfile-uris " : "") + // $NON-NLS-1$
OPTION_SHALLOW);
boolean advertiseRefInWant = transferConfig.isAllowRefInWant()
&& db.getConfig().getBoolean("uploadpack", null,
"advertiserefinwant", true);
caps.add(COMMAND_FETCH + '='
+ (transferConfig.isAllowFilter() ? OPTION_FILTER + ' ' : "")
+ (advertiseRefInWant ? CAPABILITY_REF_IN_WANT + ' ' : "")
+ (transferConfig.isAllowSidebandAll()
? OPTION_SIDEBAND_ALL + ' '
: "")
+ (cachedPackUriProvider != null ? "packfile-uris " : "")
+ OPTION_SHALLOW);
caps.add(CAPABILITY_SERVER_OPTION);
return caps;
}

Loading…
Cancel
Save