aboutsummaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* Add `HEAD` support for rpm repo files (#28309)KN4CK3R2023-12-053-2/+35
| | | | | | | | | | | Fixes https://codeberg.org/forgejo/forgejo/issues/1810 zypper uses HEAD requests to check file existence. https://github.com/openSUSE/libzypp/blob/HEAD/zypp/RepoManager.cc#L2549 https://github.com/openSUSE/libzypp/blob/HEAD/zypp-curl/ng/network/private/downloaderstates/basicdownloader_p.cc#L116 @ExplodingDragon fyi
* Remove deprecated query condition in ListReleases (#28339)Nanguan Lin2023-12-052-14/+0
| | | | | | | | | | | | | close #24057 call stack: https://github.com/go-gitea/gitea/blob/25faee3c5f5be23c99b3b7e50418fc0dbad7a41b/routers/api/v1/repo/release.go#L154 https://github.com/go-gitea/gitea/blob/ec1feedbf582b05b6a5e8c59fb2457f25d053ba2/routers/api/v1/utils/page.go#L13-L18 https://github.com/go-gitea/gitea/blob/ec1feedbf582b05b6a5e8c59fb2457f25d053ba2/services/convert/utils.go#L15-L22 ## :warning: Breaking :warning: (though it's not caused by this PR) Do not use `per_page` to specify pagination; use `limit` instead
* Convert git commit summary to valid UTF8. (#28356)darrinsmart2023-12-051-1/+2
| | | | | | | | The summary string ends up in the database, and (at least) MySQL & PostgreSQL require valid UTF8 strings. Fixes #28178 Co-authored-by: Darrin Smart <darrin@filmlight.ltd.uk>
* Fix RPM/Debian signature key creation (#28352)KN4CK3R2023-12-052-4/+3
| | | | | | | Fixes #28324 The name parameter can't contain some characters (https://github.com/keybase/go-crypto/blob/master/openpgp/keys.go#L680) but is optional. Therefore just use an empty string.
* Refactor template empty checks (#28351)KN4CK3R2023-12-0411-23/+23
|
* [skip ci] Updated licenses and gitignoresGiteaBot2023-12-042-0/+47
|
* Fix missing issue search index update when changing status (#28325)Brecht Van Lommel2023-12-031-0/+22
| | | | | Changing an issue status, assignee, labels or milestone without also adding a comment would not update the index, resulting in wrong search results.
* Keep profile tab when clicking on Language (#28320)JakobDev2023-12-011-1/+1
| | | Fixes https://codeberg.org/Codeberg/Community/issues/1355
* Fix wrong link in `protect_branch_name_pattern_desc` (#28313)yp053272023-12-011-1/+1
| | | | The current href will link to `https://domain/owner/repo/settings/branches/github.com/gobwas/glob`
* Fix links in docs (#28302)yp053272023-12-015-10/+6
| | | | | | | | | Close #28287 ## How to test it in local convert Makefile L34 into: ``` cd .tmp/upstream-docs && git clean -f && git reset --hard && git fetch origin pull/28302/head:pr28302 && git switch pr28302 ```
* Read `previous` info from git blame (#28306)KN4CK3R2023-12-013-54/+49
| | | | | | | Fixes #28280 Reads the `previous` info from the `git blame` output instead of calculating it afterwards.
* Add missing variable in tag list (#28305)JakobDev2023-11-301-0/+1
| | | | | | | | | | | This fixes a regression from #25859 If a tag has no Release, Gitea will show a Link to create a Release for the Tag if the User has the Permission to do this, but the variable to indicate that is no longer set. Used here: https://github.com/go-gitea/gitea/blob/1bfcdeef4cca0f5509476358e5931c13d37ed1ca/templates/repo/tag/list.tmpl#L39-L41
* Make pushUpdate error verbose (#28263)Earl Warren2023-11-301-1/+3
| | | | | | | | | | | - Push commits updates are run in a queue and updates can come from less traceable places such as Git over SSH, therefor add more information about on which repository the pushUpdate failed. Refs: https://codeberg.org/forgejo/forgejo/pulls/1723 (cherry picked from commit 37ab9460394800678d2208fed718e719d7a5d96f) Co-authored-by: Gusted <postmaster@gusted.xyz>
* Meilisearch: require all query terms to be matched (#28293)Brecht Van Lommel2023-11-291-4/+5
| | | | | | | | | | | | | Previously only the first term had to be matched. That default Meilisearch behavior makes sense for e.g. some kind of autocomplete to find and select a single result. But for filtering issues it means you can't narrow down results by adding more terms. This is also more consistent with other indexers and GitHub. --- Reference: https://www.meilisearch.com/docs/reference/api/search#matching-strategy
* Ignore "non-existing" errors when getDirectorySize calculates the size (#28276)wxiaoguang2023-11-291-15/+12
| | | | | | | | | The git command may operate the git directory (add/remove) files in any time. So when the code iterates the directory, some files may disappear during the "walk". All "IsNotExist" errors should be ignored. Fix #26765
* Fix required error for token name (#28267)Earl Warren2023-11-291-1/+1
| | | | | | | | | - Say to the binding middleware which locale should be used for the required error. - Resolves https://codeberg.org/forgejo/forgejo/issues/1683 (cherry picked from commit 5a2d7966127b5639332038e9925d858ab54fc360) Co-authored-by: Gusted <postmaster@gusted.xyz>
* Use appSubUrl for OAuth2 callback URL tip (#28266)Earl Warren2023-11-291-2/+3
| | | | | | | | | | - When crafting the OAuth2 callbackURL take into account `appSubUrl`, which is quite safe given that its strictly formatted. - No integration testing as this is all done in Javascript. - Resolves https://codeberg.org/forgejo/forgejo/issues/1795 (cherry picked from commit 27cb6b7956136f87aa78067d9adb5a4c4ce28a24) Co-authored-by: Gusted <postmaster@gusted.xyz>
* Ignore temporary files for directory size (#28265)Earl Warren2023-11-281-1/+5
| | | | Co-authored-by: Gusted <postmaster@gusted.xyz>
* Check for v prefix on tags for release clean name (#28257)John Olheiser2023-11-282-2/+2
|
* Use full width for project boards (#28225)Denys Konovalov2023-11-273-53/+59
| | | Inspired by #28182
* Increase "version" when update the setting value to a same value as before ↵wxiaoguang2023-11-272-1/+13
| | | | | | (#28243) Setting the same value should not trigger DuplicateKey error, and the "version" should be increased
* Fix issue will be detected as pull request when checking `First-time ↵yp053272023-11-271-1/+1
| | | | | contributor` (#28237) Fix #28224
* Fix link to `Code` tab on wiki commits (#28041)JakobDev2023-11-271-1/+1
| | | | | | | | Fixes https://codeberg.org/forgejo/forgejo/issues/1759 If you are bowing another branch than the default branch and click n the Code tab, it will take you to the root of the branch. The `BranchName` variable is also set when viewing a Wiki commit, so we also need to check if we are on a Wiki.
* Fix links in docs (#28234)yp053272023-11-273-3/+3
| | | | | | | | | Follow #28191 Changes: - `(doc/administration/config-cheat-sheet.md` is incorrect: ![image](https://github.com/go-gitea/gitea/assets/18380374/1c417dd7-61a0-49ba-8d50-871fd4c9bf20) - remove `../../`
* Fix actions when tagging (#28061)Lunny Xiao2023-11-252-1/+9
| | | | | | | close https://github.com/go-gitea/gitea/issues/28053 --------- Co-authored-by: techknowlogick <techknowlogick@gitea.io>
* Fix comment permissions (#28213)Lunny Xiao2023-11-2534-105/+417
| | | | This PR will fix some missed checks for private repositories' data on web routes and API routes.
* Docs: Replace deprecated IS_TLS_ENABLED mailer setting in email setup (#28205)CodeShakingSheep2023-11-252-2/+2
| | | | | | | | | In the [docs for email setup](https://docs.gitea.com/administration/email-setup) `mailer.IS_TLS_ENABLED` is mentioned which was replaced by `mailer.PROTOCOL` in release 1.18.0 according to https://blog.gitea.com/release-of-1.18.0/ . This change wasn't reflected in the docs for email setup. I just replaced the deprecated mailer setting.
* Fix delete-orphaned-repos (#28200)pitpalme2023-11-241-2/+2
| | | | | | | gitea doctor failed at checking and fixing 'delete-orphaned-repos', because table name 'user' needs quoting to be correctly recognized by at least PostgreSQL. fixes #28199
* Refactor graceful manager to use shared code (#28073)wxiaoguang2023-11-243-174/+119
| | | | Make "windows" and "unix" share as much code as possible. No logic change.
* Fix some incorrect links in docs (#28191)yp053272023-11-247-7/+5
| | | | | | | | | https://gitea.com/gitea/gitea-docusaurus/actions/runs/661/jobs/0#jobstep-9-39 I noticed that there are many warning logs in building docs. It is causing 404 in docs.gitea.com now, so we need to fix it. And there are also some other problems in v1.19 which can not be done in this PR. ps: Are there any good methods to test this in local?
* Remove workaround in disk-clean.yml (#28195)Nanguan Lin2023-11-241-15/+0
| | | | According to https://github.com/jlumbroso/free-disk-space/issues/17, the issue has been fixed in the main branch.
* Use db.Find instead of writing methods for every object (#28084)Lunny Xiao2023-11-2488-685/+611
| | | | For those simple objects, it's unnecessary to write the find and count methods again and again.
* Edit Discord Badge (#28188)NintenHero2023-11-231-1/+1
| | | | Use white Discord icon. Label the badge as "Discord". Use the official Discord logo's color value of 5865F2.
* Use restricted sanitizer for repository description (#28141)Earl Warren2023-11-233-5/+56
| | | | | | | | | | | | | | | - Currently the repository description uses the same sanitizer as a normal markdown document. This means that element such as heading and images are allowed and can be abused. - Create a minimal restricted sanitizer for the repository description, which only allows what the postprocessor currently allows, which are links and emojis. - Added unit testing. - Resolves https://codeberg.org/forgejo/forgejo/issues/1202 - Resolves https://codeberg.org/Codeberg/Community/issues/1122 (cherry picked from commit 631c87cc2347f0036a75dcd21e24429bbca28207) Co-authored-by: Gusted <postmaster@gusted.xyz>
* Use full width for PR comparison (#28182)Nanguan Lin2023-11-231-2/+2
| | | | | | | | | | | | Follow-up #22844 close #28142 Before ![ksnip_20231123-183906](https://github.com/go-gitea/gitea/assets/70063547/78428a22-b0a0-45f9-9458-7fd5ec73aa29) After ![full](https://github.com/go-gitea/gitea/assets/70063547/047242cf-9d6c-4b3a-9f92-54102740c27e) Co-authored-by: Giteabot <teabot@gitea.io>
* Make CORS work for oauth2 handlers (#28184)wxiaoguang2023-11-233-0/+10
| | | | | | Fix #25473 Although there was `m.Post("/login/oauth/access_token", CorsHandler()...`, it never really worked, because it still lacks the "OPTIONS" handler.
* Fix missing buttons (#28179)Nanguan Lin2023-11-231-0/+4
| | | | | | | | | | | | fix #28173 regression #25948 That PR is supposed to only change the style but somehow delete a code snippet. See the diff(https://github.com/go-gitea/gitea/pull/25948/files#diff-7c36d66fe058f4ff9f2beaac73cf710dca45b350d0dd98daf806828a4745fe62L125-L129) for details. --------- Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
* Revert "Fix EOL handling in web editor" (#28101)Nanguan Lin2023-11-223-22/+6
| | | | Reverts go-gitea/gitea#27141 close #28097
* Fix swagger title (#28164)yp053272023-11-222-2/+2
| | | | ![image](https://github.com/go-gitea/gitea/assets/18380374/380859b2-a643-42fd-b53e-78c93c05c826) Don't know why there's a `.` behind. 🤔
* Fix the description about the default setting for action in quick start ↵yp053272023-11-222-2/+2
| | | | | | | | document (#28160) Since #27054, Actions are enabled by default. so we should also edit the document. 😃 ps: I think this should be backport to 1.21.0.
* Do not display search box when there's no packages yet (#28146)yp053272023-11-211-0/+2
| | | | | | | | | | | | | | Before: ![image](https://github.com/go-gitea/gitea/assets/18380374/3012f544-7ff5-4ccb-ac80-ce24d50abe97) After: ![image](https://github.com/go-gitea/gitea/assets/18380374/4084312a-9ac0-4103-8c93-ea178ae24493) ![image](https://github.com/go-gitea/gitea/assets/18380374/3c47d175-0735-476d-8979-da2bc0a4fc95) ![image](https://github.com/go-gitea/gitea/assets/18380374/033c6a81-d1f7-4426-8063-5793d0b47462)
* Add guide page to actions when there's no workflows (#28145)yp053272023-11-214-0/+16
| | | | | | | | | Before: ![image](https://github.com/go-gitea/gitea/assets/18380374/599d40c1-9b8d-4189-9286-c9c36fb780dd) After: ![image](https://github.com/go-gitea/gitea/assets/18380374/848a73d1-aaec-478f-93a7-adcc7ee18907)
* Fix no ActionTaskOutput table waring (#28149)yp053272023-11-211-0/+4
| | | | | | | | | | | | | | | Reproduce: - Create a new Gitea instance - Register a runner - Create a repo and add a workflow - Check the log, you will see warnings: ![image](https://github.com/go-gitea/gitea/assets/18380374/5f1278e0-114b-48bc-8113-8ba1404d9975) It comes from: ![image](https://github.com/go-gitea/gitea/assets/18380374/c2807831-e137-4229-9536-87f6114c8a5b) The reason is that we forgot registering `ActionTaskOutput` model. So `action_table_output` table will be missing in your db.
* Fix empty action run title (#28113)Lunny Xiao2023-11-212-1/+2
| | | Fix #27901
* Use "is-loading" to avoid duplicate form submit for code comment (#28143)wxiaoguang2023-11-211-19/+28
| | | | | | | When the form is going to be submitted, add the "is-loading" class to show an indicator and avoid user UI events. When the request finishes (success / error), remove the "is-loading" class to make user can interact the UI.
* Fix typo in `packages.cleanup.success` (#28133)Jason Song2023-11-201-1/+1
| | | | Follow https://github.com/go-gitea/gitea/pull/28129#discussion_r1398971596
* Add edit option for README.md (#28071)JakobDev2023-11-202-0/+7
| | | | | | | Fix #28059 ![grafik](https://github.com/go-gitea/gitea/assets/15185051/07adc216-954e-486b-bfda-df3bc15f2089)
* Remove autofocus in search box (#28033)yp053272023-11-2012-12/+12
| | | | Mentioned here: https://github.com/go-gitea/gitea/pull/27982#issuecomment-1807923026
* Add missing `packages.cleanup.success` (#28129)Jason Song2023-11-201-0/+1
| | | | | | | Used at https://github.com/go-gitea/gitea/blob/a3348bfc4d565328f3608b1ee555f61be9fce1c3/routers/web/admin/packages.go#L111 <img width="1325" alt="image" src="https://github.com/go-gitea/gitea/assets/9418365/60edc1fa-eea8-4d74-a7ec-96bd5461a53f">
* Update docs for docusaurus v3 (#28125)John Olheiser2023-11-205-10/+10
| | | | | Updates the docs for usage with docusaurus v3 Signed-off-by: jolheiser <john.olheiser@gmail.com>