60 Commits (418be61040dd05f2e058f5bc20697c1fe177cf75)

Author SHA1 Message Date
Mario Lubenka fcbac38d6f Unifies pagination template usage (#6531) (#6533) 5 years ago
kolaente 0b510725c9 Feature: Archive repos (#5009) 6 years ago
Lunny Xiao eabbddcd98
Restrict permission check on repositories and fix some problems (#5314)
* fix units permission problems

* fix some bugs and merge LoadUnits to repoAssignment

* refactor permission struct and add some copyright heads

* remove unused codes

* fix routes units check

* improve permission check

* add unit tests for permission

* fix typo

* fix tests

* fix some routes

* fix api permission check

* improve permission check

* fix some permission check

* fix tests

* fix tests

* improve some permission check

* fix some permission check

* refactor AccessLevel

* fix bug

* fix tests

* fix tests

* fix tests

* fix AccessLevel

* rename CanAccess

* fix tests

* fix comment

* fix bug

* add missing unit for test repos

* fix bug

* rename some functions

* fix routes check
6 years ago
Lunny Xiao 6bdc556b7f
Fix some webhooks bugs (#3981)
* fix some webhooks bugs

* update vendor

Signed-off-by: Bo-Yi Wu <appleboy.tw@gmail.com>

* fix test

* fix clearlabels

* fix pullrequest webhook bug fix #3492

* update release webhook description

* remove unused code

* fix push webhook in pull request

* small changes
6 years ago
Morgan Bazalgette 65861900cd Handle refactor (#3339)
* Replace all ctx.Handle with ctx.ServerError or ctx.NotFound

* Change Handle(403) to NotFound, avoid using macaron's NotFound
7 years ago
Ethan Koenig 596308f213 Fix missing branch in release bug (#3108) 7 years ago
Lunny Xiao 0d80af649a Add init support of orgmode document type on file view and readme (#2525)
* add init support of orgmode document type on file view and readme

* fix imports

* fix imports and readmeExist

* fix imports order

* fix format

* remove unnecessary convert
7 years ago
Lauris BH 7a0297819d Sync releases table with tags on push and for mirrors (#2459)
* Sync releases table with tags on push and for mirrors

* Code style fixes

* Fix api to return only releases

* Optimize release creation and update
Minimize posibility of race conditions

* Fix release lower tag name updating

* handle tag reference update by addionally comparing commit id
7 years ago
Lauris BH 783b1967e2 Fix release display and correct paging (#2080) 7 years ago
iszla 3f9016430f Pagination on releases page (#2035)
* Added count to GetReleasesByRepoID so pagination will work

* Separated it out to a new function, can then also leave the API part unaffected

* Remove extra whitespace added in untouched function

* Added comment and corrected name in error handler

* Account for if the user is owner or not in the count

* Also check if repo is draft

* revert back to the correct count in the ReleasesToDisplay loop

* Fixed lint error regarding else with return statement

* Use Cond struct instead of string, corrected name in error handler

* Removed unused return variable names
7 years ago
Ethan Koenig 4df1a24096 Let not-logged-in users view releases (#1999) 7 years ago
Ethan Koenig 817a405118 Fix paginater length (#1866) 7 years ago
Ethan Koenig b900c04316 Display draft releases (#1854)
* Display draft releases

* Include ctx.User in user cache

* Integration test
7 years ago
Bo-Yi Wu 75f1afd1fd fix: tag contain character ) will http 500 on release page (#1670) 7 years ago
Lunny Xiao 45a324b437 fix releases count and resolved #764 (#857) 8 years ago
Thomas Boerger 78535fb08e Allow custom public files (#782)
* Allow custom public files

* Gofmt code, lots of places not related to this pr
8 years ago
Philip Couling 64375d875b Attach to release (#673)
* Moved attachaments POST url from /issues/attachments to /attachments

* Implemented attachment upload on release page

* Implemented downloading attachments on the release page

* Added zip and gzip files to default allowed attachments

* Implemented uploading attachments on edit release

* Renamed UploadIssueAttachment to UploadAttachment
8 years ago
Lunny Xiao 7209917fd7 bug fix release 8 years ago
Lunny Xiao 61306fa737 Make releases faster than before and resolved #490 (#588)
* make releases faster than before and resolved #490

* fix comment
8 years ago
Lunny Xiao 3c7116382f change the default action when deleting a release to not delete tag 8 years ago
Lunny Xiao 2d1a1fce93 Cache users on list releases (#527) 8 years ago
Lunny Xiao 15c3d14d55 fixed vulnerabilities on deleting release (#399) 8 years ago
Lunny Xiao 3917ed45de golint fixed for routers (#208) 8 years ago
Sandro Santilli cd339263d9 Allow updating draft releases while keeping them as draft
Closes #162
8 years ago
Thibault Meyer ddee4c8b58
Normalize files with gofmt 8 years ago
Sandro Santilli 4247304f5a Update import paths from github.com/go-gitea to code.gitea.io (#135)
- Update import paths from github.com/go-gitea to code.gitea.io
- Fix import path for travis

See https://docs.travis-ci.com/user/languages/go#Go-Import-Path
8 years ago
Kim "BKC" Carlbäcker 86fb1a0cb1 Add Pagination to Releases-page 8 years ago
Rémy Boulanouar 2d68bd1ef9 Change import reference to match gitea instead of gogs (#37) 8 years ago
Unknwon 3f7f4852ef #2246 fully support of webhooks for pull request 8 years ago
Thibault Meyer 53c573ed02 Fix #3314: Cannot edit release with tag name contains slash (#3434) 8 years ago
Thibault Meyer 30fda0f1ae Fix #3315: Release dont use tag creation date (#3374)
* Fix #3315: Release dont use tag creation date

* Simplify code and apply gofmt

* remove useless block (ctx.Repo.GitRepo.GetTag) on EditReleasePost

* apply gofmt on modified files
8 years ago
마누엘 fe60ca408b routers/repo/release: Use correct branch reference (#3330)
When calculating the current behind commit count the calculation should
use the current release target to get the total commit count. Should the
release target not exist anymore the calculation will return zero for
the newest release on that target. Older releases on that target will then
use that calculated commit count as reference.

The only use case that is now somehow invalid is when the release target
was merged / deleted after a tag on that release target:

    master 1 - - - - - - - 6
            \             /
    branch   2 - 3 - 4 - 5

When `4` is the last tag on branch `branch` and the branch `branch` is not
yet deleted the calculated numbers would be:

    1 commits to branch since this release

Now if the branch `branch` gets deleted the calculation function will not
find the branch and use the commit count of the newest release (`4`) as
reference resulting in:

    0 commit to branch since this release

This fixes #3326
8 years ago
Unknwon 1f2e173a74 Refactor User.Id to User.ID 8 years ago
Unknwon c912494609 #3076 detect invalid tag name git error 8 years ago
Unknwon 514382e2eb Rename module: middleware -> context 8 years ago
Unknwon 9cf7f3e46f Remove duplicated of code 8 years ago
Unknwon d5a3021a7d Make markdown as an independent module 8 years ago
Martin Hartkorn 6b3e47b103 Removed HTTP 500 error on the release page when a user deleted their account 9 years ago
Unknwon 9a2e43bff2 move out git module and #1573 send push hook 9 years ago
Unknwon e538ff2770 fix #1829 and fix #890 9 years ago
Unknwon 987dcc5372 fix #1383 9 years ago
Unknwon 29ed7872f8 repo sidebar active class 9 years ago
Unknwon 18de67380c fix #1958 9 years ago
Unknwon 3a81fdf092 rename fields 9 years ago
Unknwon dea3a8c6a4 WIP: create PR - choose branch 9 years ago
Peter Smit ed89b39984 Updating context and fixing permission issues
The boolean flags in the repo context have been replaced with mode and two methods

Also, the permissions have been brought more in line with https://help.github.com/articles/permission-levels-for-an-organization-repository/ , Admin Team members are able to change settings of their repositories.
10 years ago
Unknwon bc8721fb6c Finish new UI for release page 10 years ago
Unknwon 23eec25274 Fix #605, fix #255, fix #101 10 years ago
Unknwon 5c4bc3c848 Huge updates!!!!! Be careful to merge!!!! 10 years ago
Unknwon 8dd07c0ddd New UI merge in progress 10 years ago