summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* Support running subtests manually (#10988)Mura Li2020-04-071-6/+6
| | | | | | Since GNU Make does not allow '/' in the target patterns, we tranlate the subsequent '.' into '/' for "go test -run". Co-authored-by: guillep2k <18600385+guillep2k@users.noreply.github.com>
* Fix Ctrl-Enter shortcut for issues (#10986)Michael Kuhn2020-04-071-0/+2
| | | | | | | | | | The js-quick-submit class needs to be applied to SimpleMDE's input field, which is currently only done for wiki pages. Fixes #10937 Co-authored-by: Lauris BH <lauris@nix.lv> Co-authored-by: zeripath <art27@cantab.net> Co-authored-by: guillep2k <18600385+guillep2k@users.noreply.github.com>
* [feature] provide `OwnerName` field for README template (#10981)j.yao.SUSE2020-04-062-1/+2
| | | | Co-Authored-By: 6543 <6543@obermui.de> Co-authored-by: techknowlogick <techknowlogick@gitea.io>
* [Docs] Add Note to Readme-Template about Variable Espansion (#10983)65432020-04-061-3/+6
| | | | | * add note with Espansion VarNames * add context of Name
* [skip ci] Updated translations via CrowdinGiteaBot2020-04-061-0/+600
|
* Add docs for gmail (#10995)zeripath2020-04-061-0/+16
| | | | | | | Fix #10971 Signed-off-by: Andrew Thornton <art27@cantab.net> Co-authored-by: Lauris BH <lauris@nix.lv>
* Fix release counter on API repository info (#10968)65432020-04-064-7/+25
| | | | | | Use the same mechanism as the webpage for calculating the release count Fix #10946
* add request review from specific reviewers feature in pull request (#10756)赵智超2020-04-0624-67/+714
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * add request review feature in pull request add a way to notify specific reviewers to review like github , by add or delet a special type review . The acton is is similar to Assign , so many code reuse the function and items of Assignee, but the meaning and result is different. The Permission style is is similar to github, that only writer can add a review request from Reviewers, but the poster can recall and remove a review request after a reviwer has revied even if he don't have Write Premission. only manager , the poster and reviewer of a request review can remove it. The reviewers can be requested to review contain all readers for private repo , for public, contain all writers and watchers. The offical Review Request will block merge if Reject can block it. an other change: add ui otify for Assignees. Co-authored-by: guillep2k <18600385+guillep2k@users.noreply.github.com> Co-authored-by: Lauris BH <lauris@nix.lv> Signed-off-by: a1012112796 <1012112796@qq.com> * new change * add placeholder string * do some changes follow #10238 to add review requests num on lists also change icon for review requests to eye Co-authored-by: Lauris BH <lauris@nix.lv>
* Users should not be able to prohibit their own login (#10970)赵智超2020-04-062-2/+8
| | | | | | | | | | | | | | | | * ui: limit managers prohibit themself to login Because I think it's crazy and not reasonale , that if a user can prohibit themself to login. so suggest limit this choice on ui Signed-off-by: a1012112796 <1012112796@qq.com> * skip self Prohibit Login in post event handle * fix comment Co-authored-by: zeripath <art27@cantab.net> Co-authored-by: John Olheiser <john.olheiser@gmail.com> Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
* Change default charset for MySQL on install to utf8mb4 (#10989)zeripath2020-04-061-3/+3
| | | | | Signed-off-by: Andrew Thornton <art27@cantab.net> Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
* Mulitple Gitea Doctor improvements (#10943)zeripath2020-04-064-64/+472
| | | | | | | | | | | | | | * Add `gitea doctor --list` flag to list the checks that will be run, including those by default * Add `gitea doctor --run` to run specific checks * Add `gitea doctor --all` to run all checks * Add db version checker * Add non-default recalculate merge bases check/fixer to doctor * Add hook checker (Fix #9878) and ensure hooks are executable (Fix #6319) * Fix authorized_keys checker - slight change of functionality here because parsing the command is fragile and we should just check if the authorized_keys file is essentially the same as what gitea would produce. (This is still not perfect as order matters - we should probably just md5sum the two files.) * Add SCRIPT_TYPE check (Fix #10977) * Add `gitea doctor --fix` to attempt to fix what is possible to easily fix * Add `gitea doctor --log-file` to set the log-file, be it a file, stdout or to switch off completely. (Fixes previously undetected bug with certain xorm logging configurations - see @6543 comment.) Signed-off-by: Andrew Thornton <art27@cantab.net>
* Turn off go modules for xgo and gxz (#10963)John Olheiser2020-04-062-6/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Turn off go modules for xgo and gxz Signed-off-by: jolheiser <john.olheiser@gmail.com> * Add test release for PR Signed-off-by: jolheiser <john.olheiser@gmail.com> * Try with go modules off Signed-off-by: jolheiser <john.olheiser@gmail.com> * Revert Makefile, force a release test Signed-off-by: jolheiser <john.olheiser@gmail.com> * Turn on GOPROXY for release Signed-off-by: jolheiser <john.olheiser@gmail.com> * CI Signed-off-by: jolheiser <john.olheiser@gmail.com> * CI Signed-off-by: jolheiser <john.olheiser@gmail.com> * Final commit Signed-off-by: jolheiser <john.olheiser@gmail.com>
* Migrate ActivityHeatmap to Vue SFC (#10953)Gary Kim2020-04-062-92/+83
| | | | | | | | | | | | | | | * Migrate ActivityHeatmap to Vue SFC Signed-off-by: Gary Kim <gary@garykim.dev> * Readd vue compiler alias Signed-off-by: Gary Kim <gary@garykim.dev> * Remove unneeded use of v-html Signed-off-by: Gary Kim <gary@garykim.dev> Co-authored-by: zeripath <art27@cantab.net>
* Allow X in addition to x in tasks (#10979)zeripath2020-04-051-2/+2
| | | Signed-off-by: Andrew Thornton <art27@cantab.net>
* [skip ci] Updated translations via CrowdinGiteaBot2020-04-051-11/+11
|
* fix merge box icon color bug (#10974)赵智超2020-04-051-2/+1
| | | | | that because need some space beturn ``text`` and color defines Signed-off-by: a1012112796 <1012112796@qq.com>
* Fix cross compile (#10952)Lunny Xiao2020-04-052-1/+16
| | | | | | | | | | | | | * Fix cross compile * Add test for cross compile * Fix drone * Fix drone * Also prevent CC environment not to generate Co-authored-by: zeripath <art27@cantab.net>
* Add gitea-vet (#10948)John Olheiser2020-04-0555-101/+2990
| | | | | | | | | | | | | | | | | * Add copyright Signed-off-by: jolheiser <john.olheiser@gmail.com> * Add gitea-vet and fix non-compliance Signed-off-by: jolheiser <john.olheiser@gmail.com> * Combine tools.go into build.go and clean up Signed-off-by: jolheiser <john.olheiser@gmail.com> * Remove extra GO111MODULE=on Signed-off-by: jolheiser <john.olheiser@gmail.com>
* Prevent support libraries from compiling into Gitea (#10964)guillep2k2020-04-053-5/+7
| | | | | | | | | | | * Prevent support libraries from compiling into Gitea * Fix tag position * Fix golangci-lint errors * Refactor to make it work Co-authored-by: Guillermo Prandi <guillep2k@users.noreply.github.com>
* Fix scrollbar issues in dropdowns (#10897)silverwind2020-04-042-9/+13
| | | | | | | | | | | * Fix scrollbar issues in dropdowns Fixes: https://github.com/go-gitea/gitea/pull/10835 * remove wrapping * grammar Co-authored-by: guillep2k <18600385+guillep2k@users.noreply.github.com>
* Adjust label padding (#10957)mrsdizzie2020-04-041-0/+4
| | | | | | | * Adjust label padding * fix less complaint * Make top/bottom padding a bit smaller to create better label look
* Avoiding directory execution on hook (#10954) (#10955)Vasil Mikhalenya2020-04-047-9/+9
| | | * test -x is not enough https://stackoverflow.com/a/39489087
* Enable GO111MODULE=on globally in Makefile (#10939)mrsdizzie2020-04-041-16/+16
| | | | | | | Now that our minimum required go version is 1.12 we can remove code that disables GO111MODULE globally and turn it on, so each command doesn't need it set specifically. Also fixes a small bug with make pr that didn't work because GO111MODULE=on wasn't set Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
* Move gocovmerge as vendor (#10947)Lunny Xiao2020-04-046-4/+382
| | | | | | | | | * Move gocovmerge as vendor * Update Makefile Co-Authored-By: guillep2k <18600385+guillep2k@users.noreply.github.com> Co-authored-by: guillep2k <18600385+guillep2k@users.noreply.github.com>
* Add titles and improve messages on sidebar menus (#10872)赵智超2020-04-049-91/+145
| | | | | | | | | | | | | | | | | | | * ui: add more message on sidebar menus * add title on the menus * show some message instead of hide choose bar when have nothing to choose * add simply filter for each menus * do same changes in mew_form.tmpl * remove some unusefull comments in mew_form.tmpl Signed-off-by: a1012112796 <1012112796@qq.com> * do review suggestions * add filter message on sidebar filter * change IsIssueWriter to HasIssuesOrPullsWritePermission Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com> Co-authored-by: guillep2k <18600385+guillep2k@users.noreply.github.com>
* Rename scripts to build and add revive command as a new build tool command ↵Lunny Xiao2020-04-03182-1227/+15833
| | | | | (#10942) Co-authored-by: techknowlogick <techknowlogick@gitea.io>
* Update docs to 1.11.4 (#10941)techknowlogick2020-04-031-1/+1
|
* Fix rebase conflict detection in git 2.26 (#10929)zeripath2020-04-031-6/+23
| | | | | | | | | | | | | * Fix rebase conflict detection in git 2.26 Git changed the technique used in rebase from simple apply-patches to use merge. This breaks our conflict detection code. Signed-off-by: Andrew Thornton <art27@cantab.net> * As per @techknowlogick reduce copying Signed-off-by: Andrew Thornton <art27@cantab.net>
* Generate Diff and Patch direct from Pull head (#10936)zeripath2020-04-032-20/+70
| | | | | | | | | | | | | | | | | | * Generate Diff and Patch direct from Pull head Fix #10932 Also fix "Empty Diff/Patch File when pull is merged" Closes #10934 Signed-off-by: Andrew Thornton <art27@cantab.net> * Add tests to ensure that diff does not change Signed-off-by: Andrew Thornton <art27@cantab.net> * Ensure diffs and pulls pages work if head branch is deleted too Signed-off-by: Andrew Thornton <art27@cantab.net>
* Change review status icons on PR view style to Github style (#10737)赵智超2020-04-034-22/+25
| | | | | | | | | | | * change the icon of ApproveReview pr from "eye" to "check" like github * change the icon of RejectReview pr from "x" to "request-change" like github * add "-" after "{{" which need to be one line (TODO: may be not change all) Signed-off-by: a1012112796 <1012112796@qq.com> Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com> Co-authored-by: John Olheiser <john.olheiser@gmail.com> Co-authored-by: guillep2k <18600385+guillep2k@users.noreply.github.com>
* [UI] language status icon size (#10749)j.yao.SUSE2020-04-021-5/+7
| | | | | | | | | | | | | | | | | * language status icon size change the repository language status icon size * Update _base.less * fix: eslint rule length-zero-no-unit * [ui] .color-icon change size ti 14px * Update web_src/less/_base.less * Update web_src/less/_base.less Co-authored-by: Lauris BH <lauris@nix.lv>
* [skip ci] Updated translations via CrowdinGiteaBot2020-04-011-3/+32
|
* Prevent deadlock in pull_service.GetDiverging(pr) (#10905)65432020-04-012-47/+10
| | | | | * Switch to use a temporary repository instead of adding remotes to the base gitea repository to prevent deadlocking the base gitea repository. * Add documentation on how to use func **createTemporaryRepo**
* Changelog v1.11.4 (#10916) (#10917)65432020-04-011-0/+14
| | | | | | | | | | | * output of changelog * Apply suggestions from code review * Update CHANGELOG.md Co-authored-by: zeripath <art27@cantab.net> Co-authored-by: zeripath <art27@cantab.net>
* [Docs] Database Preparation - Connection over TLS (#10889)Bagas Sanjaya2020-04-011-0/+133
| | | | | | | | | | | | | | | | | * Database Preparation - Connection over TLS * Step 6 MySQL edit - have been created [before -> earlier] - recreate user, [and this time] * Apply suggestions from @guillep2k Co-Authored-By: guillep2k <18600385+guillep2k@users.noreply.github.com> * certificat[e] typo Co-authored-by: guillep2k <18600385+guillep2k@users.noreply.github.com> Co-authored-by: Lauris BH <lauris@nix.lv>
* Only update merge_base in checker if not already merged (#10908)zeripath2020-04-012-2/+2
| | | | | | | | Fix #10766 Signed-off-by: Andrew Thornton <art27@cantab.net> Co-authored-by: guillep2k <18600385+guillep2k@users.noreply.github.com> Co-authored-by: Lauris BH <lauris@nix.lv>
* [skip ci] Updated translations via CrowdinGiteaBot2020-04-0125-0/+50
|
* Exclude vendor dirs from git CRLF normalization (#10911)silverwind2020-04-0110-1000/+1003
| | | | | | | | | | | * Exclude vendor dirs from git CRLF normalization Should get rid of a few warnings like at the end of `lint-backend` like https://drone.gitea.io/go-gitea/gitea/23117/1/4 * make vendor Co-authored-by: John Olheiser <john.olheiser@gmail.com> Co-authored-by: guillep2k <18600385+guillep2k@users.noreply.github.com>
* Add Organization Wide Labels (#10814)mrsdizzie2020-04-0139-315/+1627
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Add organization wide labels Implement organization wide labels similar to organization wide webhooks. This lets you create individual labels for organizations that can be used for all repos under that organization (so being able to reuse the same label across multiple repos). This makes it possible for small organizations with many repos to use labels effectively. Fixes #7406 * Add migration * remove comments * fix tests * Update options/locale/locale_en-US.ini Removed unused translation string * show org labels in issue search label filter * Use more clear var name * rename migration after merge from master * comment typo * update migration again after rebase with master * check for orgID <=0 per guillep2k review * fmt * Apply suggestions from code review Co-Authored-By: guillep2k <18600385+guillep2k@users.noreply.github.com> * remove unused code * Make sure RepoID is 0 when searching orgID per code review * more changes/code review requests * More descriptive translation var per code review * func description/delete comment when issue label deleted instead of hiding it * remove comment * only use issues in that repo when calculating number of open issues for org label on repo label page * Add integration test for IssuesSearch API with labels * remove unused function * Update models/issue_label.go Co-Authored-By: guillep2k <18600385+guillep2k@users.noreply.github.com> * Use subquery in GetLabelIDsInReposByNames * Fix tests to use correct orgID * fix more tests * IssuesSearch api now uses new BuildLabelNamesIssueIDsCondition. Add a few more tests as well * update comment for clarity * Revert previous code change now that we can use the new BuildLabelNamesIssueIDsCondition * Don't sort repos by date in IssuesSearch API After much debugging I've found a strange issue where in some cases MySQL will return a different result than other enigines if a query is sorted by a null collumn. For example with our integration test data where we don't set updated_unix in repository fixtures: SELECT `id`, `owner_id`, `owner_name`, `lower_name`, `name`, `description`, `website`, `original_service_type`, `original_url`, `default_branch`, `num_watches`, `num_stars`, `num_forks`, `num_issues`, `num_closed_issues`, `num_pulls`, `num_closed_pulls`, `num_milestones`, `num_closed_milestones`, `is_private`, `is_empty`, `is_archived`, `is_mirror`, `status`, `is_fork`, `fork_id`, `is_template`, `template_id`, `size`, `is_fsck_enabled`, `close_issues_via_commit_in_any_branch`, `topics`, `avatar`, `created_unix`, `updated_unix` FROM `repository` ORDER BY updated_unix DESC LIMIT 15 OFFSET 45 Returns different results for MySQL than other engines. However, the similar query: SELECT `id`, `owner_id`, `owner_name`, `lower_name`, `name`, `description`, `website`, `original_service_type`, `original_url`, `default_branch`, `num_watches`, `num_stars`, `num_forks`, `num_issues`, `num_closed_issues`, `num_pulls`, `num_closed_pulls`, `num_milestones`, `num_closed_milestones`, `is_private`, `is_empty`, `is_archived`, `is_mirror`, `status`, `is_fork`, `fork_id`, `is_template`, `template_id`, `size`, `is_fsck_enabled`, `close_issues_via_commit_in_any_branch`, `topics`, `avatar`, `created_unix`, `updated_unix` FROM `repository` ORDER BY updated_unix DESC LIMIT 15 OFFSET 30 Returns the same results. This causes integration tests to fail on MySQL in certain cases but would never show up in a real installation. Since this API call always returns issues based on the optionally provided repo_priority_id or the issueID itself, there is no change to results by changing the repo sorting method used to get ids earlier in the function. * linter is back! * code review * remove now unused option * Fix newline at end of files * more unused code * update to master * check for matching ids before query * Update models/issue_label.go Co-Authored-By: 6543 <6543@obermui.de> * Update models/issue_label.go * update comments * Update routers/org/setting.go Co-authored-by: Lauris BH <lauris@nix.lv> Co-authored-by: guillep2k <18600385+guillep2k@users.noreply.github.com> Co-authored-by: 6543 <6543@obermui.de>
* Add accordion to release list and compact non-latest (#10910)John Olheiser2020-03-311-23/+30
| | | Signed-off-by: jolheiser <john.olheiser@gmail.com>
* Various Merge Base fixes (#10786)zeripath2020-03-314-8/+148
| | | | | | | | | * Fix broken merge base migration v128 for merged PR * Allow PRs with deleted base branches to still show diff * as per @lunny Co-authored-by: Lauris BH <lauris@nix.lv>
* Fix milestones too many SQL variables bug (#10880)Lunny Xiao2020-03-315-105/+135
| | | | | | | | | * Fix milestones too many SQL variables bug * Fix test * Don't display repositories with no milestone and fix tests * Remove unused code and add some comments
* Upgrade golangci-lint to 1.24.0 (#10894)zeripath2020-03-307-16/+16
| | | | | | | * upgrade golangci-lint to 1.24.0 to allow go 1.14 compatibility * fix golangci-lint errors * make make golangci-lint work when out of go-path Signed-off-by: Andrew Thornton <art27@cantab.net>
* Split dashboard elements into separate template files (#10885)mrsdizzie2020-03-303-117/+119
| | | | | | | | | | | | | | * Split dashboard elements into separate template files No code change just Move Heatmap and Repo list/search into separate template files (like feeds and navbar already are). This will let a user more easily replace dashboard.tmpl without regularly becoming out of sync with fixes or changes to the actual code. Fixes #10870 * End file with an empty line Co-authored-by: zeripath <art27@cantab.net>
* [skip ci] Updated translations via CrowdinGiteaBot2020-03-301-0/+7
|
* Use subquery to instead In (#10874)Lunny Xiao2020-03-303-26/+45
| | | | | | | | | * Use subquery to instead In * Support excludedLabelNames on issues options * Fix tests Co-authored-by: zeripath <art27@cantab.net>
* Add IIS Reverse Proxy documentation (#10881)zeripath2020-03-301-0/+56
| | | | | | | | | | | | | | | | * Add IIS Reverse Proxy documentation @mahdiit in #10748 described how to set up IIS as a reverse proxy. This PR adds these to our documentation. Close #10748 Signed-off-by: Andrew Thornton <art27@cantab.net> * Update docs/content/doc/usage/reverse-proxies.en-us.md Co-Authored-By: mrsdizzie <info@mrsdizzie.com> Co-authored-by: mrsdizzie <info@mrsdizzie.com>
* [skip ci] Updated translations via CrowdinGiteaBot2020-03-2913-26/+0
|
* Protect against NPEs in notifications list (#10879)zeripath2020-03-292-22/+75
| | | | | | | | | | | | Unfortunately there appears to be potential race with notifications being set before the associated issue has been committed. This PR adds protection in to the notifications list to log any failures and remove these notifications from the display. References #10815 - and prevents the panic but does not completely fix this. Signed-off-by: Andrew Thornton <art27@cantab.net>
* Change the order of issues.closed_by to list opening user first (#10876)zeripath2020-03-291-2/+2
| | | | | | | Fix #8266 Signed-off-by: Andrew Thornton <art27@cantab.net> Co-authored-by: techknowlogick <techknowlogick@gitea.io>