This is an aggregated NOTICE file for the projects included\r
in this distribution or linked to by this distribution.\r
\r
+---------------------------------------------------------------------------\r
+Bootstrap\r
+---------------------------------------------------------------------------\r
+ Bootstrap, released under the\r
+ Apache Software License, Version 2.0.\r
+\r
+ http://twitter.github.com/bootstrap\r
+\r
---------------------------------------------------------------------------\r
google-code-prettify\r
---------------------------------------------------------------------------\r
<copy todir="${docs.output.dir}">\r
<!-- Copy selected Gitblit resources -->\r
<fileset dir="${project.resources.dir}">\r
- <include name="background.png" />\r
- <include name="gitblit.css" />\r
+ <include name="bootstrap.130.css" />\r
+ <include name="bootstrap.gb.css" />\r
<include name="markdown.css" />\r
- <include name="gitblt_25.png" />\r
+ <include name="gitblt_25_white.png" />\r
<include name="gitblt-favicon.png" />\r
<include name="lock_go_16x16.png" />\r
<include name="lock_pull_16x16.png" />\r
<copy todir="${project.site.dir}">\r
<!-- Copy selected Gitblit resources -->\r
<fileset dir="${project.resources.dir}">\r
- <include name="background.png" />\r
- <include name="gitblit.css" />\r
+ <include name="bootstrap.130.css" />\r
+ <include name="bootstrap.gb.css" />\r
<include name="markdown.css" />\r
- <include name="gitblt_25.png" />\r
+ <include name="gitblt_25_white.png" />\r
<include name="gitblt-favicon.png" />\r
<include name="lock_go_16x16.png" />\r
<include name="lock_pull_16x16.png" />\r
# SINCE 0.6.0\r
web.showFederationRegistrations = false\r
\r
-# This is the message display above the repositories table.\r
+# This is the message displayed when *web.authenticateViewPages=true*.\r
+# This can point to a file with Markdown content.\r
+# Specifying "gitblit" uses the internal login message.\r
+#\r
+# SINCE 0.6.1\r
+web.loginMessage = gitblit\r
+\r
+# This is the message displayed above the repositories table.\r
# This can point to a file with Markdown content.\r
# Specifying "gitblit" uses the internal welcome message.\r
#\r
\r
**%VERSION%** ([go](http://code.google.com/p/gitblit/downloads/detail?name=%GO%)|[war](http://code.google.com/p/gitblit/downloads/detail?name=%WAR%)|[fedclient](http://code.google.com/p/gitblit/downloads/detail?name=%FEDCLIENT%)) based on [%JGIT%][jgit] *released %BUILDDATE%*\r
\r
+- improved: updated ui with Twitter's Bootstrap CSS toolkit\r
+<br/>**New:** *web.loginMessage = gitblit*\r
- fixed: Null pointer exception if did not set federation strategy (issue 20)\r
- fixed: Gitblit GO allows SSL renegotiation if running on Java 1.6.0_22 or later\r
- added: IUserService.setup(IStoredSettings) for custom user service implementations\r
\r
## Federation Pull Registration Keys\r
\r
-<table class="text">\r
+<table>\r
<tr><th>federation.N.url</th>\r
<td>string</td>\r
<td>the url of the origin Gitblit instance *(required)*</td>\r
### Bundled Dependencies\r
The following dependencies are bundled with Gitblit.\r
\r
+- [Bootstrap](http://twitter.github.com/bootstrap) (Apache 2.0)\r
- [google-code-prettify](http://code.google.com/p/google-code-prettify) (Apache 2.0)\r
- [Commons Daemon](http://commons.apache.org/daemon) (Apache 2.0)\r
- magnifying glass search icon courtesy of [Gnome](http://gnome.org) (Creative Commons CC-BY)\r
### Current Release\r
**%VERSION%** ([go](http://code.google.com/p/gitblit/downloads/detail?name=%GO%)|[war](http://code.google.com/p/gitblit/downloads/detail?name=%WAR%)|[fedclient](http://code.google.com/p/gitblit/downloads/detail?name=%FEDCLIENT%)) based on [%JGIT%][jgit] *released %BUILDDATE%*\r
\r
+- improved: updated ui with Twitter's Bootstrap CSS toolkit\r
+<br/>**New:** *web.loginMessage = gitblit*\r
- fixed: Null pointer exception if did not set federation strategy (issue 20)\r
- fixed: Gitblit GO allows SSL renegotiation if running on Java 1.6.0_22 or later\r
- added: IUserService.setup(IStoredSettings) for custom user service implementations\r
- </div>\r
- <div style="margin-top:10px" class="page_footer">\r
- <div style="float:right;">{0}</div>\r
- The content of this page is licensed under the <a href="http://creativecommons.org/licenses/by/3.0">Creative Commons Attribution 3.0 License</a>.\r
- </div>\r
+ </div> <!-- markdown -->\r
+ <div style="margin-top:10px" class="page_footer">\r
+ <div style="float:right;">{0}</div>\r
+ The content of this page is licensed under the <a href="http://creativecommons.org/licenses/by/3.0">Creative Commons Attribution 3.0 License</a>.\r
+ </div> \r
+ </div> <!-- content -->\r
+ </div> <!-- container --> \r
</body>\r
</html>
\ No newline at end of file
<html>\r
<head>\r
<title>Gitblit</title>\r
- <link rel="stylesheet" type="text/css" href="./gitblit.css"/>\r
+ <link rel="stylesheet" type="text/css" href="./bootstrap.130.css"/>\r
+ <link rel="stylesheet" type="text/css" href="./bootstrap.gb.css"/>\r
<link rel="stylesheet" type="text/css" href="./markdown.css"/>\r
<link rel="shortcut icon" type="image/png" href="./gitblt-favicon.png" />\r
<meta name="ROBOTS" content="INDEX, NOFOLLOW">\r
<script type="text/javascript" src="prettify/prettify.js"></script>\r
<link href="prettify/prettify.css" type="text/css" rel="stylesheet" /> \r
</head>\r
- <body style="width:900px" onload="prettyPrint()">\r
- <div class="page_header">\r
- <a title="gitblit homepage" href="http://gitblit.com/">\r
- <img src="./gitblt_25.png" width="79" height="25" alt="gitblit" class="logo"/>\r
- </a>\r
- <span style="color:black;">{0}</span>\r
+ <body style="padding-top:40px;" onload="prettyPrint()">\r
+ <div class="topbar">\r
+ <div class="fill">\r
+ <div class="container">\r
+ <a class="brand" href="http://gitblit.com" title="gitblit homepage">\r
+ <img src="gitblt_25_white.png" width="79" height="25" alt="gitblit" class="logo"/>\r
+ </a>\r
+ <ul class="nav">\r
+ {1} \r
+ </ul>\r
+ </div>\r
+ </div>\r
</div>\r
- <div class="page_nav">{1}</div>\r
- <div class="markdown">
\ No newline at end of file
+ <div class="container">\r
+ <div class="content">\r
+ <div class="markdown">
\ No newline at end of file
- </div>\r
- <div style="margin-top:10px" class="page_footer">\r
- <div style="float:right;">{0}</div>\r
- The content of this page is licensed under the <a href="http://creativecommons.org/licenses/by/3.0">Creative Commons Attribution 3.0 License</a>.\r
- </div>\r
+ </div> <!-- markdown -->\r
+ <div style="margin-top:10px" class="page_footer">\r
+ <div style="float:right;">{0}</div>\r
+ The content of this page is licensed under the <a href="http://creativecommons.org/licenses/by/3.0">Creative Commons Attribution 3.0 License</a>.\r
+ </div> \r
+ </div> <!-- content -->\r
+ </div> <!-- container --> \r
</body>\r
</html>
\ No newline at end of file
<html>\r
<head>\r
<title>Gitblit</title>\r
- <link rel="stylesheet" type="text/css" href="./gitblit.css"/>\r
+ <link rel="stylesheet" type="text/css" href="./bootstrap.130.css"/>\r
+ <link rel="stylesheet" type="text/css" href="./bootstrap.gb.css"/>\r
<link rel="stylesheet" type="text/css" href="./markdown.css"/>\r
<link rel="shortcut icon" type="image/png" href="./gitblt-favicon.png" />\r
<meta name="ROBOTS" content="INDEX">\r
\r
<!-- ANALYTICS -->\r
</head>\r
- <body style="width:900px" onload="prettyPrint()">\r
- <a href="http://github.com/gitblit"><img style="position: absolute; top: 0; right: 0; border: 0;" src="https://d3nwyuy0nl342s.cloudfront.net/img/30f550e0d38ceb6ef5b81500c64d970b7fb0f028/687474703a2f2f73332e616d617a6f6e6177732e636f6d2f6769746875622f726962626f6e732f666f726b6d655f72696768745f6f72616e67655f6666373630302e706e67" alt="Fork me on GitHub"></a>\r
- <div class="page_header">\r
- <a title="gitblit homepage" href="http://gitblit.com/">\r
- <img src="./gitblt_25.png" width="79" height="25" alt="gitblit" class="logo"/>\r
- </a>\r
- <span style="color:black;">{0}</span>\r
- <!-- Google Plus One -->\r
- <g:plusone></g:plusone>\r
+ <body style="padding-top:40px;" onload="prettyPrint()">\r
+ <div class="topbar">\r
+ <div class="fill">\r
+ <div class="container">\r
+ <a class="brand" href="http://gitblit.com" title="gitblit homepage">\r
+ <img src="gitblt_25_white.png" width="79" height="25" alt="gitblit" class="logo"/>\r
+ </a>\r
+ \r
+ <!-- Google Plus One -->\r
+ <g:plusone></g:plusone>\r
+ \r
+ <ul class="nav">\r
+ {1} \r
+ </ul>\r
+ </div>\r
+ </div>\r
</div>\r
- <div class="page_nav">{1}</div>\r
- <div class="markdown">
\ No newline at end of file
+ <div class="container">\r
+ <div class="content">\r
+ <div class="markdown">
\ No newline at end of file
}\r
\r
ul, ol {\r
- margin:0 !important;\r
+ margin-bottom: 10px !important;\r
}\r
\r
hr {\r
font-size:12px;\r
border:0px;\r
padding: 0;\r
+ line-height: 1.35em;\r
}\r
\r
table {\r
padding-right: 1px;\r
}\r
\r
+img.overview {\r
+ float:right;\r
+ border:1px solid #CCCCCC;\r
+}\r
+\r
div.header, div.commitHeader, table.repositories th {\r
background-color:#e0e0e0;\r
background-repeat:repeat-x;\r
-webkit-border-radius:0;-moz-border-radius:0x;border-radius:0;\r
vertical-align: top;\r
background: url(search-icon.png) no-repeat 4px center;\r
- color: #ddd;\r
background-color: transparent;\r
border: 1px solid transparent;\r
+ outline: none;\r
padding: 2px 2px 2px 22px;\r
+ text-shadow: none;\r
margin: 0px;\r
+ \r
+ color: #ddd;\r
}\r
\r
div.search input:hover, div.search input:focus {\r
- background: url(search-icon.png) no-repeat 4px center;\r
- color: white;\r
+ background-color: transparent;\r
+ border: 1px solid transparent;\r
+ padding: 2px 2px 2px 22px;\r
+ text-shadow: none;\r
+ \r
+ color: #ddd;\r
border-bottom: 1px solid #ff9900; \r
- outline: none;\r
}\r
\r
-div.search input:focused { \r
- background: url(search-icon.png) no-repeat 4px center;\r
+div.search input:focus {\r
+ color: white;\r
+}\r
+\r
+/* div.search input:focused { */\r
+/* background-color: transparent; */\r
+/* border: 1px solid transparent; */\r
+/* padding: 2px 2px 2px 22px; */\r
+/* text-shadow: none; */\r
+/* } */\r
+\r
+div.login input:focus {\r
+ background-color: rgba(255, 255, 255, 0.6); \r
+ text-shadow: none;\r
color: white;\r
- border-bottom: 1px solid #ff9900; \r
- outline: none;\r
- padding: 0 !important;\r
}\r
\r
div.commit_message {\r
--- /dev/null
+## Please Login\r
+\r
+Pleaes enter your credentials to access this Gitblit site.\r
\r
System.out.println(MessageFormat.format("Generating site from {0} Markdown Docs in {1} ",\r
markdownFiles.length, sourceFolder.getAbsolutePath()));\r
- String linkPattern = "<a href=''{0}''>{1}</a>";\r
+ String linkPattern = "<li><a href=''{0}''>{1}</a></li>";\r
StringBuilder sb = new StringBuilder();\r
for (File file : markdownFiles) {\r
String documentName = getDocumentName(file);\r
@SuppressWarnings({ "unchecked", "rawtypes" })\r
@Override\r
protected boolean isPageAuthorized(Class pageClass) {\r
+ if (RepositoriesPage.class.equals(pageClass)) {\r
+ // allow all requests to get to the RepositoriesPage with its inline\r
+ // authentication form\r
+ return true;\r
+ }\r
+\r
if (BasePage.class.isAssignableFrom(pageClass)) {\r
boolean authenticateView = GitBlit.getBoolean(Keys.web.authenticateViewPages, true);\r
boolean authenticateAdmin = GitBlit.getBoolean(Keys.web.authenticateAdminPages, true);\r
gb.missingUsername = Missing Username\r
gb.edit = edit\r
gb.searchTypeTooltip = Select Search Type\r
-gb.searchTooltip = Search Gitblit\r
+gb.searchTooltip = Search {0}\r
gb.delete = delete\r
gb.docs = docs\r
gb.accessRestriction = access restriction\r
\r
@Override\r
public void onSubmit() {\r
- setResponsePage(RepositoriesPage.class);\r
+ setResponsePage(UsersPage.class);\r
}\r
};\r
cancel.setDefaultFormProcessing(false);\r
import java.io.FileReader;\r
import java.io.InputStream;\r
import java.io.InputStreamReader;\r
+import java.text.MessageFormat;\r
\r
import org.apache.wicket.Component;\r
import org.apache.wicket.markup.html.basic.Label;\r
import com.gitblit.Keys;\r
import com.gitblit.utils.MarkdownUtils;\r
import com.gitblit.utils.StringUtils;\r
+import com.gitblit.wicket.GitBlitWebSession;\r
import com.gitblit.wicket.WicketUtils;\r
import com.gitblit.wicket.panels.RepositoriesPanel;\r
\r
super();\r
setupPage("", "");\r
\r
+ // check to see if we should display a login message\r
+ boolean authenticateView = GitBlit.getBoolean(Keys.web.authenticateViewPages, true);\r
+ if (authenticateView && !GitBlitWebSession.get().isLoggedIn()) {\r
+ String messageSource = GitBlit.getString(Keys.web.loginMessage, "gitblit");\r
+ String message = readMarkdown(messageSource, "login.mkd");\r
+ Component repositoriesMessage = new Label("repositoriesMessage", message);\r
+ add(repositoriesMessage.setEscapeModelStrings(false));\r
+ add(new Label("repositoriesPanel"));\r
+ return;\r
+ }\r
+\r
// Load the markdown welcome message\r
String messageSource = GitBlit.getString(Keys.web.repositoriesMessage, "gitblit");\r
+ String message = readMarkdown(messageSource, "welcome.mkd");\r
+ Component repositoriesMessage = new Label("repositoriesMessage", message)\r
+ .setEscapeModelStrings(false).setVisible(message.length() > 0);\r
+ add(repositoriesMessage);\r
+ RepositoriesPanel repositories = new RepositoriesPanel("repositoriesPanel", showAdmin,\r
+ null, getAccessRestrictions());\r
+ // push the panel down if we are hiding the admin controls and the\r
+ // welcome message\r
+ if (!showAdmin && !repositoriesMessage.isVisible()) {\r
+ WicketUtils.setCssStyle(repositories, "padding-top:5px;");\r
+ }\r
+ add(repositories);\r
+ }\r
+\r
+ private String readMarkdown(String messageSource, String resource) {\r
String message = "";\r
if (messageSource.equalsIgnoreCase("gitblit")) {\r
- // Read default welcome message\r
- try {\r
- ContextRelativeResource res = WicketUtils.getResource("welcome.mkd");\r
- InputStream is = res.getResourceStream().getInputStream();\r
- InputStreamReader reader = new InputStreamReader(is);\r
- message = MarkdownUtils.transformMarkdown(reader);\r
- reader.close();\r
- } catch (Throwable t) {\r
- message = "Failed to read default welcome message!";\r
- error(message, t, false);\r
- }\r
+ // Read default message\r
+ message = readDefaultMarkdown(resource);\r
} else {\r
- // Read user-supplied welcome message\r
+ // Read user-supplied message\r
if (!StringUtils.isEmpty(messageSource)) {\r
File file = new File(messageSource);\r
if (file.exists()) {\r
}\r
}\r
}\r
- Component repositoriesMessage = new Label("repositoriesMessage", message)\r
- .setEscapeModelStrings(false).setVisible(message.length() > 0);\r
- add(repositoriesMessage);\r
- RepositoriesPanel repositories = new RepositoriesPanel("repositoriesPanel", showAdmin,\r
- null, getAccessRestrictions());\r
- // push the panel down if we are hiding the admin controls and the\r
- // welcome message\r
- if (!showAdmin && !repositoriesMessage.isVisible()) {\r
- WicketUtils.setCssStyle(repositories, "padding-top:5px;");\r
+ return message;\r
+ }\r
+\r
+ private String readDefaultMarkdown(String file) {\r
+ String message;\r
+ try {\r
+ ContextRelativeResource res = WicketUtils.getResource(file);\r
+ InputStream is = res.getResourceStream().getInputStream();\r
+ InputStreamReader reader = new InputStreamReader(is);\r
+ message = MarkdownUtils.transformMarkdown(reader);\r
+ reader.close();\r
+ } catch (Throwable t) {\r
+ message = MessageFormat.format("Failed to read default message from {0}!", file);\r
+ error(message, t, false);\r
}\r
- add(repositories);\r
+ return message;\r
}\r
}\r
String extra = item.getModelObject();\r
PageRegistration pageReg = registeredPages.get(extra);\r
item.add(new LinkPanel("extraLink", null, getString(pageReg.translationKey),\r
- pageReg.pageClass, WicketUtils.newRepositoryParameter(repositoryName))\r
- /*.setEnabled(!extra.equals(pageWicketId))*/);\r
+ pageReg.pageClass, WicketUtils.newRepositoryParameter(repositoryName)));\r
}\r
};\r
add(extrasView);\r
\r
void setTranslatedAttributes() {\r
WicketUtils.setHtmlTooltip(get("searchType"), getString("gb.searchTypeTooltip"));\r
- WicketUtils.setHtmlTooltip(get("searchBox"), getString("gb.searchTooltip"));\r
+ WicketUtils.setHtmlTooltip(get("searchBox"), MessageFormat.format(getString("gb.searchTooltip"), repositoryName));\r
WicketUtils.setInputPlaceholder(get("searchBox"), getString("gb.search"));\r
}\r
\r
public void onSubmit() {\r
SearchType searchType = searchTypeModel.getObject();\r
String searchString = searchBoxModel.getObject();\r
+ if (searchString == null) {\r
+ // FIXME IE intermittently has no searchString. Wicket bug?\r
+ return;\r
+ }\r
for (SearchType type : SearchType.values()) {\r
if (searchString.toLowerCase().startsWith(type.name().toLowerCase() + ":")) {\r
searchType = type;\r
</ul>\r
\r
<form class="pull-right" wicket:id="loginForm">\r
- <input wicket:id="username" class="input-small" type="text" placeholder="Username">\r
- <input wicket:id="password" class="input-small" type="password" placeholder="Password">\r
- <button class="btn primary" type="submit">Sign in</button>\r
+ <div class="login">\r
+ <input wicket:id="username" class="input-small" type="text" />\r
+ <input wicket:id="password" class="input-small" type="password" />\r
+ <button class="btn primary" type="submit"><wicket:message key="gb.login"></wicket:message></button>\r
+ </div>\r
</form>\r
</div>\r
</div>\r
import com.gitblit.models.UserModel;\r
import com.gitblit.utils.StringUtils;\r
import com.gitblit.wicket.GitBlitWebSession;\r
+import com.gitblit.wicket.WicketUtils;\r
\r
/**\r
* Root page is a topbar, navigable page like Repositories, Users, or\r
}\r
}\r
};\r
- loginForm.add(new TextField<String>("username", username));\r
- loginForm.add(new PasswordTextField("password", password));\r
+ TextField<String> unameField = new TextField<String>("username", username);\r
+ WicketUtils.setInputPlaceholder(unameField, getString("gb.username"));\r
+ loginForm.add(unameField);\r
+ PasswordTextField pwField = new PasswordTextField("password", password);\r
+ WicketUtils.setInputPlaceholder(pwField, getString("gb.password"));\r
+ loginForm.add(pwField);\r
add(loginForm);\r
if (GitBlit.getBoolean(Keys.web.authenticateViewPages, true)\r
|| GitBlit.getBoolean(Keys.web.authenticateAdminPages, true)) {\r