Added setting to control length of abbreviated commit hash id
| | |
| | | # SINCE 0.9.0
|
| | | web.allowLuceneIndexing = true
|
| | |
|
| | | # Controls the length of shortened commit hash ids
|
| | | #
|
| | | # SINCE 1.2.0
|
| | | web.shortCommitIdLength = 8
|
| | |
|
| | | # Use Clippy (Flash solution) to provide a copy-to-clipboard button.
|
| | | # If false, a button with a more primitive JavaScript-based prompt box will
|
| | | # offer a 3-step (click, ctrl+c, enter) copy-to-clipboard alternative.
|
| | |
| | | **New:** *git.garbageCollectionHour = 0*
|
| | | **New:** *git.defaultGarbageCollectionThreshold = 500k*
|
| | | **New:** *git.defaultGarbageCollectionPeriod = 7 days*
|
| | | - Added setting to control length of shortened commit ids |
| | | **New:** *web.shortCommitIdLength=8* |
| | | - Added simple project pages. A project is a subfolder off the *git.repositoriesFolder*.
|
| | | - Added support for X-Forwarded-Context for Apache subdomain proxy configurations (issue 135)
|
| | | - Delete branch feature (issue 121, Github/ajermakovics)
|
| | |
| | | def mountParameters
|
| | | def forwardSlashChar
|
| | | def includeGravatar
|
| | | def shortCommitIdLength
|
| | | def commitCount = 0
|
| | | def commands
|
| | | def writer = new StringWriter();
|
| | |
| | | }
|
| | |
|
| | | def writeCommit(commit) {
|
| | | def abbreviated = repository.newObjectReader().abbreviate(commit.id, 8).name()
|
| | | def abbreviated = repository.newObjectReader().abbreviate(commit.id, shortCommitIdLength).name()
|
| | | def author = commit.authorIdent.name
|
| | | def email = commit.authorIdent.emailAddress
|
| | | def message = commit.shortMessage
|
| | |
| | | mailWriter.url = url
|
| | | mailWriter.mountParameters = gitblit.getBoolean(Keys.web.mountParameters, true)
|
| | | mailWriter.includeGravatar = gitblit.getBoolean(Keys.web.allowGravatar, true)
|
| | | mailWriter.shortCommitIdLength = GitBlit.getInteger(Keys.web.shortCommitIdLength, 8)
|
| | |
|
| | | def content = mailWriter.write()
|
| | |
|
| | |
| | | }
|
| | |
|
| | | protected String getShortObjectId(String objectId) {
|
| | | return objectId.substring(0, 8);
|
| | | return objectId.substring(0, GitBlit.getInteger(Keys.web.shortCommitIdLength, 8));
|
| | | }
|
| | |
|
| | | protected void addRefs(Repository r, RevCommit c) {
|