bug fixed

release/v1.15
Lunny Xiao 2014-03-14 23:57:14 +08:00
parent b27e8e87f8
commit d80f43ca81
2 changed files with 5 additions and 5 deletions

View File

@ -305,11 +305,11 @@ func GetReposFiles(userName, reposName, branchName, rpath string) ([]*RepoFile,
if rpath != "" {
rpath = rpath + "/"
}
fmt.Println("...", rpath, "...")
//fmt.Println("...", rpath, "...")
tree.Walk(func(dirname string, entry *git.TreeEntry) int {
if dirname == rpath {
fmt.Println("====", dirname, "==", entry.Name)
//fmt.Println("====", dirname, "==", entry.Name)
repofiles = append(repofiles, &RepoFile{
entry.Id,
entry.Filemode,

View File

@ -14,8 +14,6 @@
<li><a href="//{{.RepositoryLink}}/branch/develop">develop</a></li>
</ul>
</div>
<ol class="breadcrumb">
<li class="root dir">{{.Repository.Name}}</li>
{{$paths := .Paths}}
{{ $username := .Username}}
{{ $reponame := .Reponame}}
@ -23,6 +21,8 @@
{{ $treenames := .Treenames}}
{{ $n := len $treenames}}
{{ $l := Subtract $n 1}}
<ol class="breadcrumb">
<li class="root dir"><a href="/{{$username}}/{{$reponame}}/tree/{{$branchname}}">{{.Repository.Name}}</a></li>
{{range $i, $v := $treenames}}
<li class="dir">
{{if eq $i $l}}{{$v}}