mirror of
https://github.com/gitbucket/gitbucket.git
synced 2026-05-06 08:07:50 +02:00
Merge pull request #1530 from tkgdsg/modify_slash_escape_to_hyphen
archive naming rule modification to have comatibility with GitHub/GitHubEnerprise.
This commit is contained in:
@@ -672,7 +672,7 @@ trait RepositoryViewerControllerBase extends ControllerBase {
|
||||
val revision = name.stripSuffix(suffix)
|
||||
|
||||
val filename = repository.name + "-" +
|
||||
(if(revision.length == 40) revision.substring(0, 10) else revision).replace('/', '_') + suffix
|
||||
(if(revision.length == 40) revision.substring(0, 10) else revision).replace('/', '-') + suffix
|
||||
|
||||
using(Git.open(getRepositoryDir(repository.owner, repository.name))){ git =>
|
||||
val revCommit = JGitUtil.getRevCommitFromId(git, git.getRepository.resolve(revision))
|
||||
|
||||
Reference in New Issue
Block a user