summaryrefslogtreecommitdiffstats
path: root/src/main/java
diff options
context:
space:
mode:
authorJames Moger <james.moger@gitblit.com>2013-04-02 10:43:52 -0400
committerJames Moger <james.moger@gitblit.com>2013-04-02 10:43:52 -0400
commitb9afce4d3db8dec34b22b07c952df814efc7335f (patch)
treecfbaa4692a9a1365f1528ae2b7b66c0df8fedb44 /src/main/java
parent0f47b2f605ed4119a6042b72d3499b223f40ec90 (diff)
downloadgitblit-b9afce4d3db8dec34b22b07c952df814efc7335f.tar.gz
gitblit-b9afce4d3db8dec34b22b07c952df814efc7335f.zip
Simplify resource loading
Diffstat (limited to 'src/main/java')
-rw-r--r--src/main/java/com/gitblit/GitBlit.java11
-rw-r--r--src/main/java/login.mkd3
-rw-r--r--src/main/java/login_es.mkd3
-rw-r--r--src/main/java/login_ko.mkd3
-rw-r--r--src/main/java/login_nl.mkd3
-rw-r--r--src/main/java/login_pl.mkd3
-rw-r--r--src/main/java/login_pt_br.mkd3
-rw-r--r--src/main/java/login_zh_CN.mkd3
-rw-r--r--src/main/java/welcome.mkd3
-rw-r--r--src/main/java/welcome_es.mkd3
-rw-r--r--src/main/java/welcome_ko.mkd3
-rw-r--r--src/main/java/welcome_nl.mkd3
-rw-r--r--src/main/java/welcome_pl.mkd3
-rw-r--r--src/main/java/welcome_pt_br.mkd3
-rw-r--r--src/main/java/welcome_zh_CN.mkd3
15 files changed, 45 insertions, 8 deletions
diff --git a/src/main/java/com/gitblit/GitBlit.java b/src/main/java/com/gitblit/GitBlit.java
index 1a817ab7..566a917e 100644
--- a/src/main/java/com/gitblit/GitBlit.java
+++ b/src/main/java/com/gitblit/GitBlit.java
@@ -2997,11 +2997,10 @@ public class GitBlit implements ServletContextListener {
* Parse the properties file and aggregate all the comments by the setting
* key. A setting model tracks the current value, the default value, the
* description of the setting and and directives about the setting.
- * @param referencePropertiesInputStream
*
* @return Map<String, SettingModel>
*/
- private ServerSettings loadSettingModels(InputStream referencePropertiesInputStream) {
+ private ServerSettings loadSettingModels() {
ServerSettings settingsModel = new ServerSettings();
settingsModel.supportsCredentialChanges = userService.supportsCredentialChanges();
settingsModel.supportsDisplayNameChanges = userService.supportsDisplayNameChanges();
@@ -3011,7 +3010,7 @@ public class GitBlit implements ServletContextListener {
// Read bundled Gitblit properties to extract setting descriptions.
// This copy is pristine and only used for populating the setting
// models map.
- InputStream is = referencePropertiesInputStream;
+ InputStream is = getClass().getResourceAsStream("/reference.properties");
BufferedReader propertiesReader = new BufferedReader(new InputStreamReader(is));
StringBuilder description = new StringBuilder();
SettingModel setting = new SettingModel();
@@ -3239,10 +3238,6 @@ public class GitBlit implements ServletContextListener {
*/
@Override
public void contextInitialized(ServletContextEvent contextEvent) {
- contextInitialized(contextEvent, contextEvent.getServletContext().getResourceAsStream("/WEB-INF/reference.properties"));
- }
-
- public void contextInitialized(ServletContextEvent contextEvent, InputStream referencePropertiesInputStream) {
servletContext = contextEvent.getServletContext();
if (settings == null) {
// Gitblit is running in a servlet container
@@ -3307,7 +3302,7 @@ public class GitBlit implements ServletContextListener {
}
}
- settingsModel = loadSettingModels(referencePropertiesInputStream);
+ settingsModel = loadSettingModels();
serverStatus.servletContainer = servletContext.getServerInfo();
}
diff --git a/src/main/java/login.mkd b/src/main/java/login.mkd
new file mode 100644
index 00000000..51a4cf71
--- /dev/null
+++ b/src/main/java/login.mkd
@@ -0,0 +1,3 @@
+## Please Login
+
+Please enter your credentials to access this Gitblit site.
diff --git a/src/main/java/login_es.mkd b/src/main/java/login_es.mkd
new file mode 100644
index 00000000..700d63f4
--- /dev/null
+++ b/src/main/java/login_es.mkd
@@ -0,0 +1,3 @@
+## Debes validarte
+
+Por favor, introduce tus credenciales para acceder Gitblit. \ No newline at end of file
diff --git a/src/main/java/login_ko.mkd b/src/main/java/login_ko.mkd
new file mode 100644
index 00000000..a48099c1
--- /dev/null
+++ b/src/main/java/login_ko.mkd
@@ -0,0 +1,3 @@
+## 로그인 하세요
+
+이 Gitblit 사이트에 접속하려면 인증정보를 입력하세요.
diff --git a/src/main/java/login_nl.mkd b/src/main/java/login_nl.mkd
new file mode 100644
index 00000000..38224c96
--- /dev/null
+++ b/src/main/java/login_nl.mkd
@@ -0,0 +1,3 @@
+## Aanmelden aub
+
+Vul aub uw aanmeldgegevens in voor toegang tot deze Gitblit site.
diff --git a/src/main/java/login_pl.mkd b/src/main/java/login_pl.mkd
new file mode 100644
index 00000000..cc7978b4
--- /dev/null
+++ b/src/main/java/login_pl.mkd
@@ -0,0 +1,3 @@
+## Zaloguj się
+
+Wprowadź swoje dane uwierzytelniające, aby uzyskać dostęp do instancji Gitblita.
diff --git a/src/main/java/login_pt_br.mkd b/src/main/java/login_pt_br.mkd
new file mode 100644
index 00000000..6a4a8570
--- /dev/null
+++ b/src/main/java/login_pt_br.mkd
@@ -0,0 +1,3 @@
+## Faça o Login
+
+Por favor, entre com suas credenciais para acessar o site Gitblit.
diff --git a/src/main/java/login_zh_CN.mkd b/src/main/java/login_zh_CN.mkd
new file mode 100644
index 00000000..09046231
--- /dev/null
+++ b/src/main/java/login_zh_CN.mkd
@@ -0,0 +1,3 @@
+## 请登录
+
+请输入身份信息以登陆Gitblit。 \ No newline at end of file
diff --git a/src/main/java/welcome.mkd b/src/main/java/welcome.mkd
new file mode 100644
index 00000000..130cd8ac
--- /dev/null
+++ b/src/main/java/welcome.mkd
@@ -0,0 +1,3 @@
+## Welcome to Gitblit
+
+A quick and easy way to host or view your own [Git](http://www.git-scm.com) repositories.
diff --git a/src/main/java/welcome_es.mkd b/src/main/java/welcome_es.mkd
new file mode 100644
index 00000000..52f290e3
--- /dev/null
+++ b/src/main/java/welcome_es.mkd
@@ -0,0 +1,3 @@
+## Bienvenid@ a Gitblit
+
+Una forma f&aacute;cil y r&aacute;pida de organizar o ver tus propios repositorios [Git](http://www.git-scm.com) \ No newline at end of file
diff --git a/src/main/java/welcome_ko.mkd b/src/main/java/welcome_ko.mkd
new file mode 100644
index 00000000..27cd65da
--- /dev/null
+++ b/src/main/java/welcome_ko.mkd
@@ -0,0 +1,3 @@
+## Gitblit 사용을 환영합니다.
+
+당신의 [Git](http://www.git-scm.com) 저장소를 운영하거나 보기 위한 빠르고 쉬운 방법.
diff --git a/src/main/java/welcome_nl.mkd b/src/main/java/welcome_nl.mkd
new file mode 100644
index 00000000..406ca1e0
--- /dev/null
+++ b/src/main/java/welcome_nl.mkd
@@ -0,0 +1,3 @@
+## Welkom bij Gitblit
+
+Een snelle en makkelijke manier voor het hosten en bekijken van uw eigen [Git](http://www.git-scm.com) repositories.
diff --git a/src/main/java/welcome_pl.mkd b/src/main/java/welcome_pl.mkd
new file mode 100644
index 00000000..bc60770a
--- /dev/null
+++ b/src/main/java/welcome_pl.mkd
@@ -0,0 +1,3 @@
+## Witaj w aplikacji Gitblit
+
+Szybko i wygodnie hostuj lub przeglądaj własne repozytoria [GIT](http://www.git-scm.com).
diff --git a/src/main/java/welcome_pt_br.mkd b/src/main/java/welcome_pt_br.mkd
new file mode 100644
index 00000000..6b30bbcd
--- /dev/null
+++ b/src/main/java/welcome_pt_br.mkd
@@ -0,0 +1,3 @@
+## Bem-Vindo ao Gitblit
+
+Uma maneira fácil e rápida de armazenar e visualizar o seus próprios repositórios [Git](http://www.git-scm.com).
diff --git a/src/main/java/welcome_zh_CN.mkd b/src/main/java/welcome_zh_CN.mkd
new file mode 100644
index 00000000..f4a651ef
--- /dev/null
+++ b/src/main/java/welcome_zh_CN.mkd
@@ -0,0 +1,3 @@
+## 欢迎访问 Gitblit
+
+快速便捷的 [Git](http://www.git-scm.com) 版本库管理方案。