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.

76 lines
3.3 KiB

  1. {{template "base/head" .}}
  2. {{template "base/navbar" .}}
  3. <div class="container" id="gogs-body">
  4. <form action="/repo/create" method="post" class="form-horizontal gogs-card" id="gogs-repo-create">
  5. <h3>Create New Repository</h3>
  6. <div class="alert alert-danger form-error{{if .HasError}}{{else}} hidden{{end}}">{{.ErrorMsg}}</div>
  7. <div class="form-group">
  8. <label class="col-md-2 control-label">Owner<strong class="text-danger">*</strong></label>
  9. <div class="col-md-8">
  10. <p class="form-control-static">{{.SignedUserName}}</p>
  11. <input type="hidden" value="{{.SignedUserId}}" name="userId"/>
  12. </div>
  13. </div>
  14. <div class="form-group {{if .Err_RepoName}}has-error has-feedback{{end}}">
  15. <label class="col-md-2 control-label">Repository<strong class="text-danger">*</strong></label>
  16. <div class="col-md-8">
  17. <input name="repo" type="text" class="form-control" placeholder="Type your repository name" value="{{.repo}}" required="required">
  18. <span class="help-block">Great repository names are short and memorable. </span>
  19. </div>
  20. </div>
  21. <div class="form-group">
  22. <label class="col-md-2 control-label">Visibility<strong class="text-danger">*</strong></label>
  23. <div class="col-md-8">
  24. <p class="form-control-static">Public</p>
  25. <input type="hidden" value="public" name="visibility"/>
  26. </div>
  27. </div>
  28. <div class="form-group {{if .Err_Description}}has-error has-feedback{{end}}">
  29. <label class="col-md-2 control-label">Description</label>
  30. <div class="col-md-8">
  31. <textarea name="desc" class="form-control" placeholder="Type your repository description">{{.desc}}</textarea>
  32. </div>
  33. </div>
  34. <div class="form-group">
  35. <label class="col-md-2 control-label">Language</label>
  36. <div class="col-md-8">
  37. <select class="form-control" name="language">
  38. <option value="">Select a language</option>
  39. {{range .LanguageIgns}}<option value="{{.}}">{{.}}</option>{{end}}
  40. </select>
  41. </div>
  42. </div>
  43. <div class="form-group">
  44. <label class="col-md-2 control-label">License</label>
  45. <div class="col-md-8">
  46. <select class="form-control" name="license">
  47. <option value="">Select a license</option>
  48. {{range .Licenses}}<option value="{{.}}">{{.}}</option>{{end}}
  49. </select>
  50. </div>
  51. </div>
  52. <div class="form-group">
  53. <div class="col-md-8 col-md-offset-2">
  54. <div class="checkbox">
  55. <label>
  56. <input type="checkbox" name="initReadme">
  57. <strong>Initialize this repository with a README</strong>
  58. </label>
  59. </div>
  60. </div>
  61. </div>
  62. <div class="form-group">
  63. <div class="col-md-offset-2 col-md-8">
  64. <button type="submit" class="btn btn-lg btn-primary">Create repository</button>
  65. <a href="/" class="text-danger">Cancel</a>
  66. </div>
  67. </div>
  68. </form>
  69. </div>
  70. {{template "base/footer" .}}