aboutsummaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* Add default storage configurations (#12813)Lunny Xiao2020-09-2919-183/+457
| | | | Signed-off-by: Andrew Thornton <art27@cantab.net> Co-authored-by: zeripath <art27@cantab.net>
* Completely quote AppPath and CustomConf paths (#12955)zeripath2020-09-285-8/+200
| | | | | | | | | | | | | | | | | | | | | | * Completely quote AppPath and CustomConf paths Properly handle spaces in AppPath and CustomConf within hooks and authorized_keys. Unfortunately here we don't seem to be able to get away with using go-shellquote as it appears that Windows doesn't play too well with singlequote quoting - therefore we will avoid singlequote quoting unless we absolutely cannot get away without it, e.g. \n or !. Fix #10813 Signed-off-by: Andrew Thornton <art27@cantab.net> * missing change Signed-off-by: Andrew Thornton <art27@cantab.net> * fix Test_CmdKeys Signed-off-by: Andrew Thornton <art27@cantab.net>
* Fix the issue reported on #12385 (#12969)zeripath2020-09-281-0/+1
| | | | | Missed setting ConnectionString on queuesettings Signed-off-by: Andrew Thornton <art27@cantab.net>
* Docs: Add missing SESSION_LIFE_TIME to Config Cheat Sheet (#12968)65432020-09-281-0/+1
| | | Co-authored-by: techknowlogick <techknowlogick@gitea.io>
* Changed width of signature avatar from auto to 16px (#12961)Victor2020-09-281-1/+1
| | | | | Signed-off-by: Victor Roest <victor@xirion.net> Co-authored-by: Antoine GIRARD <sapk@users.noreply.github.com>
* [skip ci] Updated translations via CrowdinGiteaBot2020-09-282-15/+60
|
* Mirror: Update DB on Address-Update too (#12964)65432020-09-282-5/+7
| | | | | * Mirror: Update DB on Address-Update too * new name for function to better describe
* Update Dockerfile (#12922)Antoine GIRARD2020-09-271-2/+1
|
* Allow common redis and leveldb connections (#12385)zeripath2020-09-2871-3084/+4873
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Allow common redis and leveldb connections Prevents multiple reopening of redis and leveldb connections to the same place by sharing connections. Further allows for more configurable redis connection type using the redisURI and a leveldbURI scheme. Signed-off-by: Andrew Thornton <art27@cantab.net> * add unit-test Signed-off-by: Andrew Thornton <art27@cantab.net> * as per @lunny Signed-off-by: Andrew Thornton <art27@cantab.net> * add test Signed-off-by: Andrew Thornton <art27@cantab.net> * Update modules/cache/cache_redis.go * Update modules/queue/queue_disk.go * Update modules/cache/cache_redis.go * Update modules/cache/cache_redis.go * Update modules/queue/unique_queue_disk.go * Update modules/queue/queue_disk.go * Update modules/queue/unique_queue_disk.go * Update modules/session/redis.go Co-authored-by: techknowlogick <techknowlogick@gitea.io> Co-authored-by: Lauris BH <lauris@nix.lv>
* [skip ci] Updated translations via CrowdinGiteaBot2020-09-271-0/+11
|
* Add config option to make create-on-push repositories public by default (#12936)Tait Hoyem2020-09-275-1/+8
| | | | | | | | | | | | | | | | | | | | | * Add config option to make create-on-push repositories public by default * Fix linting * Add option to 'config cheat sheet' page * Chinese translation Signed-off-by: a1012112796 <1012112796@qq.com> * Fix typo in docs * fix typo * Add option to example config Co-authored-by: Tait Hoyem <code@tait.tech> Co-authored-by: a1012112796 <1012112796@qq.com> Co-authored-by: techknowlogick <techknowlogick@gitea.io>
* [skip ci] Updated translations via CrowdinGiteaBot2020-09-271-0/+3
|
* Update GitHub docs links for SSH & GPG (#12947)Bagas Sanjaya2020-09-262-2/+2
| | | | | | | | | The links now redirected to docs.github.com. `common SSH problems` link is misredirected to `Authenticating to GitHub` page, so it has been corrected to the proper `troubleshooting SSH` page. Signed-off-by: Bagas Sanjaya <bagasdotme@gmail.com> Co-authored-by: techknowlogick <techknowlogick@gitea.io>
* [skip ci] Updated translations via CrowdinGiteaBot2020-09-261-2/+13
|
* Add a step for binding IP address for listening on remote database (#12898)Bagas Sanjaya2020-09-261-12/+23
| | | | | | | | * Add listen address configuration step * Fix numbering order Signed-off-by: Bagas Sanjaya <bagasdotme@gmail.com> Co-authored-by: Lauris BH <lauris@nix.lv>
* Proposals for cheat-sheet docs (#12946)Melroy van den Berg2020-09-261-2/+9
| | | | | | | * Propose additional settings in cheat sheet Add most used settings of app.ini to cheat sheet docs. * Fix small typo
* API: Get release by tags endpoint (#12932)Johan Van de Wauw2020-09-254-0/+140
| | | | | | | | | Get a release based on a tag name (for which a release exists). Based on: https://developer.github.com/v3/repos/releases/#get-a-release-by-tag-name Co-authored-by: 赵智超 <1012112796@qq.com> Co-authored-by: 6543 <6543@obermui.de>
* [Docs] Add all chooseable cron config options to 'app.example.ini' (#12931)赵智超2020-09-251-1/+106
| | | | | | | | | | | As title. ref: https://github.com/go-gitea/gitea/blob/master/modules/cron/tasks_basic.go https://github.com/go-gitea/gitea/blob/master/modules/cron/tasks_extended.go https://github.com/go-gitea/gitea/blob/ba20dd7a7b59157d9232de7dfa99a23b0fb0d2aa/modules/setting/cron.go#L7-L11 Signed-off-by: a1012112796 <1012112796@qq.com>
* [skip ci] Updated translations via CrowdinGiteaBot2020-09-251-2/+17
|
* Allow extended config on cron settings (#12939)zeripath2020-09-252-2/+67
| | | | | | | | * Allow extended config on cron settings Fix #12934 Signed-off-by: Andrew Thornton <art27@cantab.net>
* Add IsTemplate option in create repo ui and api (#12942)赵智超2020-09-259-0/+20
| | | | | Signed-off-by: a1012112796 <1012112796@qq.com> Co-authored-by: Lauris BH <lauris@nix.lv>
* Adopt repositories (#12920)zeripath2020-09-2531-95/+1335
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Don't automatically delete repository files if they are present Prior to this PR Gitea would delete any repository files if they are present during creation or migration. This can in certain circumstances lead to data-loss and is slightly unpleasant. This PR provides a mechanism for Gitea to adopt repositories on creation and otherwise requires an explicit flag for deletion. PushCreate is slightly different - the create will cause adoption if that is allowed otherwise it will delete the data if that is allowed. Signed-off-by: Andrew Thornton <art27@cantab.net> * Update swagger Signed-off-by: Andrew Thornton <art27@cantab.net> * Fix tests and migrate overwrite Signed-off-by: Andrew Thornton <art27@cantab.net> * as per @lunny Only offer to adopt or overwrite if the user can do that. Allow the site administrator to adopt or overwrite in all circumstances Signed-off-by: Andrew Thornton <art27@cantab.net> * Use setting.Repository.DefaultBranch for the default branch Signed-off-by: Andrew Thornton <art27@cantab.net> * Always set setting.Repository.DefaultBranch Signed-off-by: Andrew Thornton <art27@cantab.net> * update swagger Signed-off-by: Andrew Thornton <art27@cantab.net> * update templates Signed-off-by: Andrew Thornton <art27@cantab.net> * ensure repo closed Signed-off-by: Andrew Thornton <art27@cantab.net> * Rewrite of adoption as per @6543 and @lunny Signed-off-by: Andrew Thornton <art27@cantab.net> * Apply suggestions from code review * update swagger Signed-off-by: Andrew Thornton <art27@cantab.net> * missing not Signed-off-by: Andrew Thornton <art27@cantab.net> * add modals and flash reporting Signed-off-by: Andrew Thornton <art27@cantab.net> * Make the unadopted page searchable Signed-off-by: Andrew Thornton <art27@cantab.net> * Add API Signed-off-by: Andrew Thornton <art27@cantab.net> * Fix swagger Signed-off-by: Andrew Thornton <art27@cantab.net> * fix swagger Signed-off-by: Andrew Thornton <art27@cantab.net> * Handle empty and non-master branched repositories Signed-off-by: Andrew Thornton <art27@cantab.net> * placate lint Signed-off-by: Andrew Thornton <art27@cantab.net> * remove commented out code Signed-off-by: Andrew Thornton <art27@cantab.net> Co-authored-by: techknowlogick <techknowlogick@gitea.io>
* Fixed count of filtered issues when api request. (#12275)ひのしば / hinoshiba2020-09-242-29/+64
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Improved total count of issue when filtered. * Fixed size of slice when selected 1 repository. * Improved function of error check. * improved comment * Added parameter of return header. Co-authored-by: 6543 <6543@obermui.de> * Updated corresponded to the current vendored of "xorm.io/xorm". * Dedublicated it by store the Options Struct into a variable. * format code * Update routers/api/v1/repo/issue.go Co-authored-by: 6543 <6543@obermui.de> * Update routers/api/v1/repo/issue.go Co-authored-by: 6543 <6543@obermui.de> * Updated number of range. Co-authored-by: 6543 <6543@obermui.de> * Updated number of range. Co-authored-by: 6543 <6543@obermui.de> * Removed total value. * make fmt * Improved value of sql. Co-authored-by: zeripath <art27@cantab.net> * Improved value of sql. * improved message * improved message * improved message * fixed message Co-authored-by: 6543 <6543@obermui.de> Co-authored-by: zeripath <art27@cantab.net> Co-authored-by: techknowlogick <techknowlogick@gitea.io>
* [skip ci] Updated translations via CrowdinGiteaBot2020-09-241-23/+76
|
* API: GetReleaseByID return 404 if not found (#12933)65432020-09-242-2/+24
| | | | | * API: GetReleaseByID return 404 if not found * update swagger docs
* Fix Create Repository Template (#12924)65432020-09-231-8/+9
| | | Co-authored-by: zeripath <art27@cantab.net>
* [skip ci] Updated translations via CrowdinGiteaBot2020-09-232-12/+30
|
* Fix handling of migration errors (#12928)zeripath2020-09-233-15/+22
| | | | | | | | | | | | | | * Fix handling of migration errors The migration type selection screen PR did not correctly handle errors and any user input error on the migration page would simply redirect back to the selection page. This meant that the error would simply be lost and the user would be none the wiser as to what happened. Signed-off-by: Andrew Thornton <art27@cantab.net> * make gen-swagger Co-authored-by: techknowlogick <techknowlogick@gitea.io>
* [skip ci] Updated translations via CrowdinGiteaBot2020-09-223-13/+43
|
* update revive lint to latest commit (#12921)techknowlogick2020-09-22154-8495/+5958
| | | | | | | * update revive lint to latest commit * make fmt * change import
* Disable migration items when mirror is selected (#12918)mrsdizzie2020-09-221-3/+10
| | | | | | | | | * Disable migration items when mirror is selected Disable migration items when mirror option is selected to make it more clear that it isn't possible to mirror anything other than code. * allow wiki checkbox for mirrors Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
* [skip ci] Updated translations via CrowdinGiteaBot2020-09-212-4/+16
|
* Hopefully support GH enterprise (#12863)John Olheiser2020-09-213-4/+8
| | | | | | Signed-off-by: jolheiser <john.olheiser@gmail.com> Co-authored-by: zeripath <art27@cantab.net> Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
* API: NotificationSubject show Issue/Pull State (#12901)65432020-09-203-4/+10
|
* [skip ci] Updated translations via CrowdinGiteaBot2020-09-201-1/+1
|
* Fix ListUserOrgs (#12910)赵智超2020-09-211-1/+1
| | | | | | | fix #12891 Signed-off-by: a1012112796 <1012112796@qq.com> Co-authored-by: Lauris BH <lauris@nix.lv>
* [skip ci] Updated translations via CrowdinGiteaBot2020-09-201-13/+24
|
* Not using "ctx.ServerError" in api (#12907)赵智超2020-09-2010-28/+26
| | | | | | This function will render a whole html page which is not useful for API. Signed-off-by: a1012112796 <1012112796@qq.com>
* [skip ci] Updated translations via CrowdinGiteaBot2020-09-201-0/+5
|
* Update only the repository columns that need updating (#12900)zeripath2020-09-201-3/+8
| | | | | | | | | | | | We should only update is_empty, default_branch and updated time columns during commitRepoAction and not update other columns as we risk overwriting incorrect information. Fix #11823 Fix #10536 Signed-off-by: Andrew Thornton <art27@cantab.net> Co-authored-by: techknowlogick <techknowlogick@gitea.io>
* [skip ci] Updated translations via CrowdinGiteaBot2020-09-191-0/+3
|
* Add the checkbox quick button to the comment tool bar also (#12885)赵智超2020-09-201-1/+20
| | | | | | | | Just copy it from the WIKI tool bar :) Signed-off-by: a1012112796 <1012112796@qq.com> Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com> Co-authored-by: zeripath <art27@cantab.net>
* [skip ci] Updated translations via CrowdinGiteaBot2020-09-191-24/+85
|
* Add configurable Trust Models (#11712)zeripath2020-09-2029-137/+439
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Add configurable Trust Models Gitea's default signature verification model differs from GitHub. GitHub uses signatures to verify that the committer is who they say they are - meaning that when GitHub makes a signed commit it must be the committer. The GitHub model prevents re-publishing of commits after revocation of a key and prevents re-signing of other people's commits to create a completely trusted repository signed by one key or a set of trusted keys. The default behaviour of Gitea in contrast is to always display the avatar and information related to a signature. This allows signatures to be decoupled from the committer. That being said, allowing arbitary users to present other peoples commits as theirs is not necessarily desired therefore we have a trust model whereby signatures from collaborators are marked trusted, signatures matching the commit line are marked untrusted and signatures that match a user in the db but not the committer line are marked unmatched. The problem with this model is that this conflicts with Github therefore we need to provide an option to allow users to choose the Github model should they wish to. Signed-off-by: Andrew Thornton <art27@cantab.net> * Adjust locale strings Signed-off-by: Andrew Thornton <art27@cantab.net> * as per @6543 Co-authored-by: 6543 <6543@obermui.de> * Update models/gpg_key.go * Add migration for repository Signed-off-by: Andrew Thornton <art27@cantab.net> Co-authored-by: 6543 <6543@obermui.de> Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
* [skip ci] Updated translations via CrowdinGiteaBot2020-09-181-0/+2
|
* Fix panic when adding long comment (#12892)mrsdizzie2020-09-181-1/+1
| | | Previous PR #12881 causes out of bounds panic by working on wrong string.
* Switch to absolute latest pq driver (#12859)zeripath2020-09-189-14/+43
| | | | | | | | | | | This PR updates the lib/pq driver to the current master head to pick up the deadlock fix in lib/pq#993 Hopefully this will resolve our CI issues. Signed-off-by: Andrew Thornton <art27@cantab.net> Co-authored-by: techknowlogick <techknowlogick@gitea.io> Co-authored-by: Lauris BH <lauris@nix.lv>
* [skip ci] Updated translations via CrowdinGiteaBot2020-09-181-0/+17
|
* Refactor: move Commit To APIFormat Code & Lot of StopWatch related things ↵65432020-09-188-228/+230
| | | | | | | | | | | | | (#12729) * move GitCommit to APIFormat convertion into convert package * rename Commit convert functions * move stopwatch to api convertion into convert package & rm unused code & extend test * fix compare time * Gitea not Gogs ;)
* Add size limit for content of comment on action ui (#12881)赵智超2020-09-181-1/+10
| | | | | Signed-off-by: a1012112796 <1012112796@qq.com> Co-authored-by: mrsdizzie <info@mrsdizzie.com> Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>