|
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778 |
- {{/*
- {{if .LatestCommit.Author}}{{TimeSince .LatestCommit.Author.When $.Lang}}{{end}}
-
- <td class="message collapsing has-emoji">
- {{RenderCommitMessageLink $commit.Summary $.RepoLink (print $.RepoLink "/commit/" $commit.ID) $.Repository.ComposeMetas}}
- </td>
- */}}
-
- <h4 class="ui top attached header">
- {{ $n := len .TreeNames}}
- {{ $l := Subtract $n 1}}
- <span class="ui breadcrumb repo-path"><a class="section" href="{{.RepoLink}}/src/{{EscapePound .BranchNameSubURL}}">{{EllipsisString .Repository.Name 30}}</a>{{range $i, $v := .TreeNames}}<span class="divider">/</span>{{if eq $i $l}}<span class="active section">{{EllipsisString $v 30}}</span>{{else}}{{ $p := index $.Paths $i}}<span class="section"><a href="{{EscapePound $.BranchLink}}/{{EscapePound $p}}">{{EllipsisString $v 30}}</a></span>{{end}}{{end}}</span>
-
- <div class="ui right sub header">
- Latest commit:
- <a rel="nofollow" href="{{.RepoLink}}/commit/{{.LatestCommit.ID}}">
- <span class="grey has-emoji">
- {{RenderCommitMessage .LatestCommit.Summary .RepoLink $.Repository.ComposeMetas}}
- {{if IsMultilineCommitMessage .LatestCommit.Message}}
- <button class="basic compact mini ui icon button commit-button"><i class="ellipsis horizontal icon"></i></button>
- <pre class="commit-body" style="display: none;">{{RenderCommitBody .LatestCommit.Message $.RepoLink $.Repository.ComposeMetas}}</pre>
- {{end}}
- {{template "repo/commit_status" .LatestCommitStatus}}
- </span>
- </a>
- <span style="margin-left: 1em;">
- {{if .LatestCommit.Author}}{{TimeSince .LatestCommit.Author.When $.Lang}}{{end}}
- </span>
- </div>
- </h4>
- <table id="repo-files-table" class="ui fixed single line attached table">
- <tbody>
- {{if .HasParentPath}}
- <tr class="has-parent">
- <td colspan="2"><a href="{{EscapePound .BranchLink}}{{.ParentPath}}"><i class="octicon octicon-mail-reply"></i> ..</a></td>
- </tr>
- {{end}}
- {{range $item := .Files}}
- {{$entry := index $item 0}}
- {{$commit := index $item 1}}
- <tr>
- {{if $entry.IsSubModule}}
- <td>
- <span class="octicon octicon-file-submodule"></span>
- {{$refURL := $commit.RefURL AppUrl $.BranchLink}}
- {{if $refURL}}
- <a href="{{$refURL}}">{{$entry.Name}}</a> @ <a href="{{$refURL}}/commit/{{$commit.RefID}}">{{ShortSha $commit.RefID}}</a>
- {{else}}
- {{$entry.Name}} @ {{ShortSha $commit.RefID}}
- {{end}}
- </td>
- {{else}}
- <td class="name">
- {{if $entry.IsDir}}
- {{$subJumpablePathName := $entry.GetSubJumpablePathName}}
- {{$subJumpablePath := SubJumpablePath $subJumpablePathName}}
- <span class="octicon octicon-file-directory"></span>
- <a href="{{EscapePound $.TreeLink}}/{{EscapePound $subJumpablePathName}}">
- {{if eq (len $subJumpablePath) 2}}
- <span class="jumpable-path">{{index $subJumpablePath 0}}</span>{{index $subJumpablePath 1}}
- {{else}}
- {{index $subJumpablePath 0}}
- {{end}}
- </a>
- {{else}}
- <span class="octicon octicon-file-text"></span>
- <a href="{{EscapePound $.TreeLink}}/{{EscapePound $entry.Name}}">{{$entry.Name}}</a>
- {{end}}
- </td>
- {{end}}
- <td class="text grey right age">{{TimeSince $commit.Committer.When $.Lang}}</td>
- </tr>
- {{end}}
- </tbody>
- </table>
- {{if .ReadmeExist}}
- {{template "repo/view_file" .}}
- {{end}}
|