ant-notifications mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From k...@apache.org
Subject svn commit: r902405 - /ant/sandbox/antlibs/git/trunk/src/main/org/apache/ant/git/AbstractGitTask.java
Date Sat, 23 Jan 2010 13:58:40 GMT
Author: kevj
Date: Sat Jan 23 13:58:40 2010
New Revision: 902405

URL: http://svn.apache.org/viewvc?rev=902405&view=rev
Log:
-non-controversial exception message and start of support of jgit

Modified:
    ant/sandbox/antlibs/git/trunk/src/main/org/apache/ant/git/AbstractGitTask.java

Modified: ant/sandbox/antlibs/git/trunk/src/main/org/apache/ant/git/AbstractGitTask.java
URL: http://svn.apache.org/viewvc/ant/sandbox/antlibs/git/trunk/src/main/org/apache/ant/git/AbstractGitTask.java?rev=902405&r1=902404&r2=902405&view=diff
==============================================================================
--- ant/sandbox/antlibs/git/trunk/src/main/org/apache/ant/git/AbstractGitTask.java (original)
+++ ant/sandbox/antlibs/git/trunk/src/main/org/apache/ant/git/AbstractGitTask.java Sat Jan
23 13:58:40 2010
@@ -575,7 +575,18 @@
 			throw new BuildException("You must specify a gitRepo value");
 		}
 		if(!validGitRepo()) {
-			throw new BuildException("The repository [ "+ getGitRepo()+ " ] specified is not recognised");
+			throw new BuildException("The repository [ "+ getGitRepo()+ " ] specified is invalid");
 		}
 	}
+	
+	protected boolean jgitPresent() throws BuildException {
+		try {
+			Class.forName("org.eclipse.jgit.lib.Repository");
+		} catch (ClassNotFoundException e){
+			return false;
+		} catch (Exception e) {
+			throw new BuildException(e);
+		}
+		return true;
+	}
 }



Mime
View raw message