aboutsummaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* Disable unnecessary mirroring elements (#18527)Paweł Bogusławski2022-06-047-11/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Disable unnecessary mirroring elements This mod fixes disabling unnecessary mirroring elements. Related: https://github.com/go-gitea/gitea/pull/16957 Related: https://github.com/go-gitea/gitea/pull/13084 Author-Change-Id: IB#1105104 * Checkbox rendering disabled instead of hiding it Fixes: 02b45051503d4330da9757ff084c9cc5e6e60d84 Related: https://github.com/go-gitea/gitea/pull/18527#pullrequestreview-878061913 Author-Change-Id: IB#1105104 * Update custom/conf/app.example.ini Co-authored-by: silverwind <me@silverwind.io> * Update docs/content/doc/advanced/config-cheat-sheet.en-us.md Co-authored-by: silverwind <me@silverwind.io> * Mirror filter removed only when whole mirroring feature is disabled Fixes: 02b45051503d4330da9757ff084c9cc5e6e60d84 Related: https://github.com/go-gitea/gitea/pull/18527#discussion_r883268890 Author-Change-Id: IB#1105104 Co-authored-by: silverwind <me@silverwind.io>
* [skip ci] Updated translations via Crowdinwxiaoguang2022-06-041-1/+13
|
* Remove customized (unmaintained) dropdown, improve aria a11y for dropdown ↵wxiaoguang2022-06-039-4459/+195
| | | | | | | | | | | | | | | | | | | | | | | | | | | | (#19861) * Remove customized (unmaintained) dropdown, improve aria a11y for dropdown * fix repo permission * use action instead of onChange * re-order the CSS selector * fix dropdown behavior for repo permissions, make elements inside menu item non-focusable * use menu/menuitem instead of combobox/option. use tooltip(data-content) for aria-label, prevent from repeated attaching * click menu item when pressing Enter * code format * fix repo permission * repo setting: prevent from misleading users when error occurs * fine tune the repo collaboration access mode dropdown (in case the access mode is undefined in the template) Co-authored-by: zeripath <art27@cantab.net> Co-authored-by: techknowlogick <techknowlogick@gitea.io>
* Set Setpgid on child git processes (#19865)zeripath2022-06-039-0/+44
| | | | | | | | | | When Gitea is running as PID 1 git will occassionally orphan child processes leading to (defunct) processes. This PR simply sets Setpgid to true on these child processes meaning that these defunct processes will also be correctly reaped. Fix #19077 Signed-off-by: Andrew Thornton <art27@cantab.net>
* Allow postgres integration tests to run over unix pipe (#19875)zeripath2022-06-032-11/+42
|
* improvement some release related code (#19867)Lunny Xiao2022-06-037-52/+35
|
* feat: add DEFAULT_MERGE_STYLE to `repository.pull-request` section for repo ↵ttys32022-06-026-1/+15
| | | | init (#19751)
* [skip ci] Updated translations via Crowdinzeripath2022-06-031-0/+12
|
* Prevent NPE on update mirror settings (#19864)zeripath2022-06-022-2/+2
| | | | | | | | | | | | | A `repo_model.Mirror` repository field (`.Repo`) will not automatically be set, but is used without checking in mirror_pull.go:UpdateAddress. This will cause an NPE. This PR changes UpdateAddress to use the helper function GetRepository() helping prevent future NPEs but also changes modules/context/repo.go to ensure that the Mirror.Repo is set. Signed-off-by: Andrew Thornton <art27@cantab.net> Co-authored-by: techknowlogick <techknowlogick@gitea.io>
* update documents (#19868)wxiaoguang2022-06-026-95/+56
|
* Only return valid stopwatches (#19863)zeripath2022-06-021-1/+1
| | | | | | | | | | | Looking through the logs of try.gitea.io I am seeing a number of reports of being unable to APIformat stopwatches because the issueID is 0. These are invalid StopWatches and they represent a db inconsistency. This PR simply stops sending them to the eventsource. Signed-off-by: Andrew Thornton <art27@cantab.net> Co-authored-by: techknowlogick <techknowlogick@gitea.io>
* [skip ci] Updated translations via Crowdinzeripath2022-06-022-0/+2
|
* Add title attribute to dependencies in sidebar (#19807)zeripath2022-06-011-2/+2
| | | | | | | | | | | | | | | | * Add title attribute to dependencies in sidebar Add the full title as the title attribute on dependencies in the sidebar. Fix #19806 Signed-off-by: Andrew Thornton <art27@cantab.net> * as per silverwind Signed-off-by: Andrew Thornton <art27@cantab.net> Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
* Fix spelling mistake in ProcReceive (#19853)zeripath2022-06-012-3/+3
| | | | | There was a spelling mistake in the ProcReceive handler. This PR fixes this.
* Ensure responses are context.ResponseWriters (#19843)zeripath2022-05-311-0/+6
| | | | | | | | | | | | | | | In order for web.Wrap to be able to detect if a response has been written we need to wrap any non-context.ResponseWriters as a such. Otherwise responses will be incorrectly detected as non-written to and handlers can double run. In the case of GZip this handler will change the response to a non-context.RW and this failure to correctly detect response writing causes fallthrough and a NPE. Fix #19839 Signed-off-by: Andrew Thornton <art27@cantab.net>
* Fix inconsistency in doctor output (#19836)Gusted2022-05-312-4/+10
| | | | | | | | | | | | | * Fix inconsistency in doctor output - Use `logger.Info` instead of `logger.Warn` when no errors were found. * Update modules/doctor/fix16961.go Co-authored-by: delvh <dev.lh@web.de> Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com> Co-authored-by: delvh <dev.lh@web.de> Co-authored-by: techknowlogick <techknowlogick@gitea.io>
* docs: recommendations to ensure backup consistency and reliability (#19845)singuliere2022-05-311-0/+17
| | | | | | | | | | | * docs: recommendations to ensure backup consistency and reliability * s/stooping/stopping/ * Update docs/content/doc/usage/backup-and-restore.en-us.md Co-authored-by: delvh <dev.lh@web.de> Co-authored-by: delvh <dev.lh@web.de>
* feat: Add support for extra sshd_config parameters via 'Include' file (#19842)Thomas Andrade2022-05-312-0/+3
| | | Co-authored-by: techknowlogick <techknowlogick@gitea.io>
* [skip ci] Updated translations via CrowdinGiteaBot2022-05-313-1/+5
|
* docs: update the ROOT documentation and error messages (#19832)singuliere2022-05-314-6/+8
| | | | | | | | | | | | | | | * docs: update the ROOT documentation and error messages * The documentation now reflects what happens in the setting/repository.go::newRepository function: filepath.Join(AppWorkPath, RepoRootPath) was missing. * The error message displayed when RepoRootPath is not found now displays the value of RepoRootPath. Given the complexity of the construction of this value, only referring to it in the abstract is likely to be misleading to the Gitea admin trying to interpret the message. Co-authored-by: delvh <dev.lh@web.de>
* [skip ci] Updated translations via CrowdinGiteaBot2022-05-301-9/+9
|
* Add version hint in the docs when packages are available (#19838)delvh2022-05-291-1/+1
| | | | | * Add version hint in the docs when packages are available * Change italic to bold
* docs(hacking-on-gitea): fix installation instruction for elasticsearch ↵Yehonatan Ezron2022-05-291-1/+1
| | | | docker (#19829)
* Fix i18n for Link Account button, re-format tmpl (#19835)wxiaoguang2022-05-292-14/+14
|
* [skip ci] Updated translations via CrowdinGiteaBot2022-05-291-9/+9
|
* Adding button to link accounts from user settings (#19792)Mai-Lapyst2022-05-294-5/+42
| | | | | * Adding button to link accounts from user settings * Only display button to link user accounts when at least one OAuth2 provider is active
* fix(telegram): fix link bot to release tag (#19830)Yehonatan Ezron2022-05-284-5/+5
| | | | | | | * fix(telegram): fix link bot to release tag * test(webhook): fix matrixPayload Release * test(webhook): fix TestTelegramPayload Release
* Fix raw endpoint PDF file headers (#19825)Lauris BH2022-05-282-4/+12
|
* docs: FAQ: the WorkPath can be set from --work-path (#19822)singuliere2022-05-281-1/+2
|
* [skip ci] Updated translations via CrowdinGiteaBot2022-05-282-22/+196
|
* Fix duplicate paragraph in documentation (#19820)Vladimir Yakovlev2022-05-271-9/+0
|
* Make WIP prefixes case insensitive, e.g. allow `Draft` as a WIP prefix (#19780)Ondřej Čertík2022-05-263-4/+4
| | | | | | | | | | | | | | | | | | | | | The issue was that only the actual title was converted to uppercase, but not the prefix as specified in `WORK_IN_PROGRESS_PREFIXES`. As a result, the following did not work: WORK_IN_PROGRESS_PREFIXES=Draft:,[Draft],WIP:,[WIP] One possible workaround was: WORK_IN_PROGRESS_PREFIXES=DRAFT:,[DRAFT],WIP:,[WIP] Then indeed one could use `Draft` (as well as `DRAFT`) in the title. However, the link `Start the title with DRAFT: to prevent the pull request from being merged accidentally.` showed the suggestion in uppercase; so it is not possible to show it as `Draft`. This PR fixes it, and allows to use `Draft` in `WORK_IN_PROGRESS_PREFIXES`. Fixes #19779. Co-authored-by: zeripath <art27@cantab.net>
* Fix follower display on user page (#19805)silverwind2022-05-261-1/+3
|
* Show source/target branches on PR's list (#19747)IT-AlexKor2022-05-253-5/+47
| | | | | | | Add ability to show source/target branches for Pull Request's list. It can be useful to see which branches are used in each PR right in the list. Co-authored-by: Alexey Korobkov <akorobkov@cian.ru> Co-authored-by: wxiaoguang <wxiaoguang@gmail.com> Co-authored-by: Lauris BH <lauris@nix.lv>
* Github style following followers (#19482)istiak1012022-05-251-12/+1
| | | Removed tabbed following and followers from user page and added Github style following followers.
* alpine 3.16 (#19797)techknowlogick2022-05-252-4/+4
| | | Co-authored-by: 6543 <6543@obermui.de>
* Prevent loop if there is an error in GetNotificationCount (#19799)zeripath2022-05-251-1/+5
| | | | | | | | | | | | | | | | | | If the context is cancelled `.NotificationUnreadCount` in a template can cause an infinite loop with `ctx.ServerError()` being called, which creates a template that then calls `.NotificationUnreadCount` calling `GetNotificationCount()` with the cancelled context resulting in an error that calls `ctx.ServerError`... and so on... This PR simply stops calling `ctx.ServerError` in the error handler code for `.NotificationUnreadCount` as we have already started rendering and so it is too late to call `ctx.ServerError`. Additionally we skip logging the error if it's a context cancelled error. Fix #19793 Signed-off-by: Andrew Thornton <art27@cantab.net> Co-authored-by: techknowlogick <techknowlogick@gitea.io>
* Add 'make tidy' (#19800)silverwind2022-05-242-61/+10
| | | | | Convenience command to run 'go mod tidy'. The compat flag is set to the minimum supported go version instead of min version minus one which is go's default, which eliminated some checksums in go.sum as a result.
* Update document to use FHS `/usr/local/bin/gitea` instead of `/app/...` for ↵wxiaoguang2022-05-244-18/+6
| | | | | | | Docker (#19794) * Update document to use FHS `/usr/local/bin/gitea` instead of `/app/...` in Docker * Update docs/content/doc/installation/with-docker.zh-cn.md
* [skip ci] Updated translations via CrowdinGiteaBot2022-05-241-2/+1
|
* Add the possibility to allow the user to have a favicon which differs from ↵Jan-Eric Schober2022-05-234-12/+47
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | the main logo (#18542) * Changed the filename of the favicon SVG This allows the user to have a favicon which differs from the logo. * Added favicon.svg This is needed to accommodate the changes for allowing the user to have a differing logo and favicon * Adjusted page to accommodate what icon is used as favicon * Added functionality to also generate the favicon.svg via generate-images.js * Adjusted the description for the new favicon compatibility Co-authored-by: silverwind <me@silverwind.io> * Updated generate-images.js to generate favicons from a separate favicons.svg file This belongs to PR #18542. * Added description on how custom favicons can be generated * Replaced space indents with tabs * Synced changes with current state of the file * Synced changes with current state of the file Co-authored-by: silverwind <me@silverwind.io> Co-authored-by: zeripath <art27@cantab.net> Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com> Co-authored-by: Lauris BH <lauris@nix.lv>
* [skip ci] Updated translations via CrowdinGiteaBot2022-05-2323-23/+4
|
* [skip ci] Updated licenses and gitignoresGiteaBot2022-05-222-1/+19
|
* Estimate Action Count in Statistics (#19775)zeripath2022-05-213-2/+24
|
* Prevent NPE when cache service is disabled (#19703)zeripath2022-05-213-15/+25
| | | | | | | | | | | | | | The cache service can be disabled - at which point ctx.Cache will be nil and the use of it will cause an NPE. The main part of this PR is that the cache is used for restricting resending of activation mails and without this we cache we cannot restrict this. Whilst this code could be re-considered to use the db and probably should be, I think we can simply disable this code in the case that the cache is disabled. There are also several bug fixes in the /nodeinfo API endpoint. Signed-off-by: Andrew Thornton <art27@cantab.net>
* Detect truncated utf-8 characters at the end of content as still ↵zeripath2022-05-212-1/+164
| | | | | | | | | | | | | | representing utf-8 (#19773) Our character detection algorithm can potentially incorrectly detect utf-8 as iso-8859-x if there is a truncated character at the end of the partially read file. This PR changes the detection algorithm to truncated utf8 characters at the end of the buffer. Fix #19743 Signed-off-by: Andrew Thornton <art27@cantab.net>
* Add silentcodeg to MAINTAINERS (#19771)silentcodeg2022-05-211-0/+1
| | | | | | | | * Add silentcodeg to MAINTAINERS * add missing trailing g to chat nick Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com> Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
* Allows repo search to match against "owner/repo" pattern strings (#19754)Eekle2022-05-212-1/+39
| | | | | | | | | | | * Allows repo search to match against "owner/repo" pattern strings * Gofumpt * Adds test case for "owner/repo" style repo search * With "owner/repo" search terms, prioritise results which match the owner field * Fixes unquoted SQL string in repo search
* Update JS dependencies (#19767)silverwind2022-05-206-1880/+3256
| | | | | | - Update all JS dependencies minus Vue - Tested mermaid, swagger, build Co-authored-by: 6543 <6543@obermui.de>
* Nuke the incorrect permission report on /api/v1/notifications (#19761)zeripath2022-05-201-0/+5
| | | | | | | | | | | | | The permissions created in convertRepo use a minimal perm.AccessModeRead instead of correctly computing the permission for the repository. This incorrect permission is then reported to the user. I do not believe that reporting the permissions is helpful and therefore I propose we simply null these out. The user can check their permissions using a different endpoint. Fix #19759 Signed-off-by: Andrew Thornton <art27@cantab.net>