From 022931842214f04f9f4bdb1ba94f2d5feaae44e2 Mon Sep 17 00:00:00 2001
From: Konstantinos Kostarellis <kosta.grails@gmail.com>
Date: Wed, 18 Jul 2012 02:52:30 -0400
Subject: [PATCH] Added shell script equivalents to the cmd versions to generate the keystore

---
 src/com/gitblit/client/GitblitClient.java |    9 +++++++++
 1 files changed, 9 insertions(+), 0 deletions(-)

diff --git a/src/com/gitblit/client/GitblitClient.java b/src/com/gitblit/client/GitblitClient.java
index 09bcaab..ed5a133 100644
--- a/src/com/gitblit/client/GitblitClient.java
+++ b/src/com/gitblit/client/GitblitClient.java
@@ -28,6 +28,7 @@
 import java.util.TreeSet;
 
 import com.gitblit.Constants;
+import com.gitblit.Constants.AccessRestrictionType;
 import com.gitblit.GitBlitException.ForbiddenException;
 import com.gitblit.GitBlitException.NotAllowedException;
 import com.gitblit.GitBlitException.UnauthorizedException;
@@ -185,6 +186,14 @@
 			return sb.toString();
 		}
 	}
+	
+	public AccessRestrictionType getDefaultAccessRestriction() {
+		String restriction = null;
+		if (settings.hasKey(Keys.git.defaultAccessRestriction)) {
+			restriction = settings.get(Keys.git.defaultAccessRestriction).currentValue;
+		}
+		return AccessRestrictionType.fromName(restriction);
+	}
 
 	/**
 	 * Returns the list of pre-receive scripts the repository inherited from the

--
Gitblit v1.9.1