From d08be7aceb18296e9a3465787d3d09da0479eabd Mon Sep 17 00:00:00 2001 From: Benjamin Muskalla Date: Mon, 2 Aug 2010 18:00:43 +0200 Subject: [PATCH] Allow version builtin to run without git repository The version builtin should be able to run without a git directory to call it from wherever you want. Change-Id: I1a3bce662e6788b860a275ee50315af8d5cc094a Signed-off-by: Benjamin Muskalla --- org.eclipse.jgit.pgm/src/org/eclipse/jgit/pgm/Version.java | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/org.eclipse.jgit.pgm/src/org/eclipse/jgit/pgm/Version.java b/org.eclipse.jgit.pgm/src/org/eclipse/jgit/pgm/Version.java index 5bad4ef98..9b51b871f 100644 --- a/org.eclipse.jgit.pgm/src/org/eclipse/jgit/pgm/Version.java +++ b/org.eclipse.jgit.pgm/src/org/eclipse/jgit/pgm/Version.java @@ -55,4 +55,9 @@ class Version extends TextBuiltin { out.println(MessageFormat.format(CLIText.get().jgitVersion, pkg.getImplementationVersion())); } + + @Override + protected final boolean requiresRepository() { + return false; + } }