You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

53 lines
2.9 KiB

  1. {{template "ng/base/head" .}}
  2. {{template "ng/base/header" .}}
  3. <div id="repo-wrapper" class="repo-bare">
  4. <div id="repo-header" class="clear">
  5. <div class="container clear">
  6. <h1 id="repo-header-name" class="left public">
  7. <i class="mega-octicon octicon-{{if .Repository.IsPrivate}}lock{{else}}repo{{end}}"></i>
  8. <a class="author" href="{{AppSubUrl}}/{{.Repository.Owner.Name}}">{{.Repository.Owner.Name}}</a>
  9. <span class="divider">/</span>
  10. <a class="repo text-bold" href="{{.RepoLink}}">{{.Repository.Name}}</a>
  11. </h1>
  12. </div>
  13. </div>
  14. <div id="repo-content" class="clear container">
  15. <div id="repo-bare">
  16. <div id="repo-bare-start" class="panel panel-radius">
  17. <div class="panel-header">
  18. <a class="btn btn-small btn-black btn-header btn-radius right" href="{{.RepoLink}}/settings">{{.i18n.Tr "repo.settings"}}</a>
  19. <strong>{{.i18n.Tr "repo.quick_guide"}}</strong>
  20. </div>
  21. <div class="panel-content">
  22. <div id="repo-clone" class="clear text-center">
  23. <h2>{{.i18n.Tr "repo.clone_this_repo"}}</h2>
  24. <button class="btn btn-blue current left btn-left-radius" id="repo-clone-ssh" data-link="{{.CloneLink.SSH}}">SSH</button>
  25. <button class="btn btn-gray left" id="repo-clone-https" data-link="{{.CloneLink.HTTPS}}">HTTPS</button>
  26. <input id="repo-clone-url" type="text" class="ipt ipt-disabled left" value="{{.CloneLink.SSH}}" onclick="this.select()" readonly />
  27. <button class="btn btn-black left btn-right-radius" id="repo-clone-copy" data-copy-val="val" data-copy-from="#repo-clone-url">{{.i18n.Tr "repo.copy_link"}}</button>
  28. <p class="text-center" id="repo-clone-help">{{.i18n.Tr "repo.clone_helper" | Str2html}}</p>
  29. <hr/>
  30. </div>
  31. <div id="repo-bare-cmd" class="text-center">
  32. <h2>{{.i18n.Tr "repo.create_new_repo_command"}}</h2>
  33. <pre class="text-left radius"><code>touch README.md
  34. git init
  35. git add README.md
  36. git commit -m "first commit"
  37. git remote add origin <span class="clone-url">{{.CloneLink.SSH}}</span>
  38. git push -u origin master</code></pre>
  39. <br/>
  40. <hr/>
  41. </div>
  42. <div id="repo-bare-remote" class="text-center">
  43. <h2>{{.i18n.Tr "repo.push_exist_repo"}}</h2>
  44. <pre class="text-left radius"><code>git remote add origin <span class="clone-url">{{.CloneLink.SSH}}</span>
  45. git push -u origin master</code></pre>
  46. <br/>
  47. </div>
  48. </div>
  49. </div>
  50. </div>
  51. </div>
  52. </div>
  53. {{template "ng/base/footer" .}}