Merge remote-tracking branch 'jnovack/markdown'
[phorkie.git] / data / templates / display-sidebar-history.htm
index 7deacd0d038b7646a2ae2ca3eff8bd9018dc955b..bf388843395d7d800fcbbec21c7f5b039b2eac53 100644 (file)
@@ -2,17 +2,17 @@
 
 <ul class="history unstyled">
 {% for commit in repo.getHistory %}
- <li {% if commit.hash == repo.hash %}class="active"{%endif%}>
+ <li {% if commit.hash == repo.hash or (repo.hash == '' and loop.first) %}class="active"{%endif%}>
   {% spaceless %}
   {% for dot in commit.getDots %}
   <img src="/phorkie/dot-{{dot}}.png" alt="" style="padding-left:1px" width="4" height="4"/>
   {% endfor %}
   {% endspaceless %}
-  <a class="hash" href="{{repo.getLink('commit', commit.hash)}}">{{commit.hash|slice(0, 6)}}</a>
+  <a class="hash" href="{{repo.getLink('revision', commit.hash)}}">{{commit.hash|slice(0, 6)}}</a>
   <img src="{{commit.getIconUrl}}" alt="{{commit.committerName}}" title="{{commit.committerName}}" width="20"/>
   <span title="{{commit.committerTime|date('c')}}">{{dh.get(commit.committerTime)}}</span>
  </li>
 {% else %}
 <p>No commits yet</p>
 {% endfor %}
-</ul>
\ No newline at end of file
+</ul>