Prompt for passwords from the console in jgit command line tools

If we are on a Java 6 JVM we should have the Console class available,
unless the user has redirected /dev/null to stdin.  When there is a
console present we would prefer to use that for command line prompts
as that is what the user expects from a command line tool.

Change-Id: Ibaf87bb5540371d94d96d1b7e94ca002f752e5bd
Signed-off-by: Shawn O. Pearce <>
diff --git a/org.eclipse.jgit.console/.settings/org.eclipse.core.runtime.prefs b/org.eclipse.jgit.console/.settings/org.eclipse.core.runtime.prefs
new file mode 100644
index 0000000..dc57041
--- /dev/null
+++ b/org.eclipse.jgit.console/.settings/org.eclipse.core.runtime.prefs
@@ -0,0 +1,3 @@
+#Sun Oct 11 08:00:39 EEST 2009