df9d1fe8c5
Trivial fixes ( #33103 )
...
1. remove `gock` dependency, it is not needed
2. fix a regression from org private profile readme
2025-01-04 22:25:50 +00:00
e709cc76da
Make Gitea always use its internal config, ignore /etc/gitconfig
( #33076 )
...
In history, Gitea could use the system config `/etc/gitconfig` because
some users said that "they might put certNonceSeed in it"
Actually, we shouldn't not use it, because it also causes conflicts
(there are already some fixes like #28848 )
To make the system clear, I think it's worth to introduce the breaking
change: add `GIT_CONFIG_NOSYSTEM=1` to all git commands.
## ⚠️ BREAKING ⚠️
For most users, nothing need to do.
If you have made changes to `/etc/gitconfig` to affect Gitea's behavior,
you need to move these config options to Gitea's internal git config
file, it is usually in Gitea's `{AppDataPath}/home/.git` directory.
2025-01-02 20:26:48 +00:00
9ac536a904
Fix "stop time tracking button" on navbar ( #33084 )
...
release-nightly / nightly-binary (push) Waiting to run
release-nightly / nightly-docker-rootful (push) Waiting to run
release-nightly / nightly-docker-rootless (push) Waiting to run
Fix #33083
By the way (something I was working on):
1. relax color/background-color for more markup elements
2. fix a command line sentence error
2025-01-03 04:01:05 +08:00
45973a100b
Fix bleve fuzziness search ( #33078 )
...
Close #31565
2025-01-03 00:32:02 +08:00
4f386e2c5e
Refactor env var related code ( #33075 )
...
release-nightly / nightly-binary (push) Waiting to run
release-nightly / nightly-docker-rootful (push) Waiting to run
release-nightly / nightly-docker-rootless (push) Waiting to run
And add more comments
2025-01-02 11:36:50 +08:00
233b7959e0
unset XDG_HOME_CONFIG as gitea manages configuration locations ( #33067 )
...
unset XDG_CONFIG_HOME early to enable gitea to manage git configuration.
simple error checking to satisfy the linting. Closes #33039
---------
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com >
2025-01-02 06:37:35 +08:00
2564c15cb0
Remove some unnecessary template helpers ( #33069 )
...
DisableGitHooks and DisableImportLocal are only used when editing a
user, so only set them in `editUserCommon`
2025-01-01 18:02:34 +08:00
57eb9d0b64
Inherit submodules from template repository content ( #16237 )
...
release-nightly / nightly-binary (push) Waiting to run
release-nightly / nightly-docker-rootful (push) Waiting to run
release-nightly / nightly-docker-rootless (push) Waiting to run
Fix #10316
---------
Signed-off-by: Steffen Schröter <steffen@vexar.de >
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com >
2025-01-01 02:55:13 +00:00
a0853e2278
Fix unittest and repo create bug ( #33061 )
...
release-nightly / nightly-binary (push) Waiting to run
release-nightly / nightly-docker-rootful (push) Waiting to run
release-nightly / nightly-docker-rootless (push) Waiting to run
cron-translations / crowdin-pull (push) Has been skipped
1. `StatDir` was not right, fix the FIXME
2. Clarify the test cases for `IsUsableRepoName`
3. Fix regression bug in `repo-new.ts`
Fix #33060
2024-12-31 18:45:05 +08:00
e5c576e92b
Refactor maven package registry ( #33049 )
...
Close #33036
2024-12-31 05:30:52 +00:00
0387195abb
[Feature] Private README.md for organization ( #32872 )
...
Implemented #29503
---------
Co-authored-by: Ben Chang <ben_chang@htc.com >
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com >
2024-12-31 04:22:09 +00:00
1e2c8eb494
Fix settings not being loaded at CLI ( #26402 )
...
Closes #25898
The problem was that the default settings weren't being loaded
---------
Signed-off-by: cassiozareck <cassiomilczareck@gmail.com >
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com >
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com >
2024-12-30 05:54:20 +00:00
dafadf0028
Refactor fixture loading for testing ( #33024 )
...
To help binary size and testing performance
2024-12-30 04:06:57 +00:00
f4ccbd38dc
Use gitrepo.GetTreePathLatestCommit to get file lastest commit instead from latest commit cache ( #32987 )
...
The latest commit cache is currently used only for listing tree files.
However, a cold start may take longer than directly invoking the Git
command. This PR addresses the issue of slow response times when
accessing raw files, improving performance in such scenarios.
```log
gitea.log:105521:2024/12/23 08:22:18 ...eb/routing/logger.go:68:func1() [W] router: slow GET /xxxx/xxxxxx/raw/commit/xxxxxxxxxxxxxxxxxxxxxxxxxxx/.editorconfig for 172.18.0.5:53252, elapsed 3526.8ms @ repo/download.go:117(repo.SingleDownload)
```
2024-12-30 03:30:01 +00:00
e435b1900a
Refactor arch route handlers ( #32993 )
2024-12-28 03:31:46 +00:00
7bb7ba1b5b
Add show more
organizations icon in user's profile ( #32986 )
...
Close #32952
# ⚠️ Doc update is required


------
⚠️ This PR refuses to be cherry-picked by any forked projects without any
mentions.
---------
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com >
2024-12-27 02:49:50 +08:00
550abdbc24
Improve "ellipsis string" ( #32989 )
release-nightly / nightly-docker-rootful (push) Has been cancelled
release-nightly / nightly-docker-rootless (push) Has been cancelled
release-nightly / nightly-binary (push) Has been cancelled
cron-translations / crowdin-pull (push) Has been skipped
2024-12-26 14:19:35 +08:00
9bfa9f450d
Refactor "string truncate" ( #32984 )
2024-12-26 11:56:03 +08:00
594edad213
Do not render truncated links in markdown ( #32980 )
...
release-nightly / nightly-binary (push) Waiting to run
release-nightly / nightly-docker-rootful (push) Waiting to run
release-nightly / nightly-docker-rootless (push) Waiting to run
Fixes #31780
2024-12-26 00:33:55 +08:00
abaeae0b9c
Fix Azure blob object Seek
( #32974 )
...
This bug was found in a
[test](https://github.com/go-gitea/gitea/actions/runs/12464294025/job/34788152194?pr=32883#step:9:105 )
of #32883
---------
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com >
2024-12-25 04:54:52 +00:00
973363fec3
Fix maven pom inheritance ( #32943 )
...
Fix #30568
2024-12-25 04:28:37 +00:00
ca31d478ee
Refactor arch route handlers ( #32972 )
2024-12-25 04:03:14 +00:00
2a828e2798
Clarify path param naming ( #32969 )
...
release-nightly / nightly-binary (push) Waiting to run
release-nightly / nightly-docker-rootful (push) Waiting to run
release-nightly / nightly-docker-rootless (push) Waiting to run
In history (from some legacy frameworks), both `:name` and `name` are
supported as path path name, `:name` is an alias to `name`.
To make code consistent, now we should only use `name` but not `:name`.
Also added panic check in related functions to make sure the name won't
be abused in case some downstreams still use them.
2024-12-24 13:47:45 +00:00
b8b690feb9
Refactor getpatch/getdiff functions and remove unnecessary fallback ( #32817 )
...
release-nightly / nightly-binary (push) Waiting to run
release-nightly / nightly-docker-rootful (push) Waiting to run
release-nightly / nightly-docker-rootless (push) Waiting to run
cron-translations / crowdin-pull (push) Has been skipped
Extract from #32786
`git diff a..b` is equal to `git diff a b` which is different from `git
diff a...b`. For pull request, we should always
---------
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com >
2024-12-24 14:29:34 +08:00
6d5aa9218e
Refactor request context ( #32956 )
...
Introduce RequestContext: is a short-lived context that is used to store
request-specific data.
RequestContext could be used to clean form tmp files, close context git
repo, and do some tracing in the future.
Then a lot of legacy code could be removed or improved. For example:
most `ctx.Repo.GitRepo.Close()` could be removed because the git repo
could be closed when the request is done.
2024-12-24 11:43:57 +08:00
781c6df40f
Add sub issue list support ( #32940 )
...
Just like GitHub, show issue icon/title when the issue number is in a list
2024-12-24 01:54:19 +00:00
bd5d1341d4
Fix commit range paging ( #32944 )
2024-12-23 07:07:12 +00:00
462ce31530
Fix repo avatar conflict ( #32958 )
...
Continue even if the avatar deleting fails
2024-12-23 02:52:25 +00:00
fb75151fb1
fix trailing comma not matched in the case of alphanumeric issue ( #32945 )
...
Fix #32428 .
Patch the regex to match `,`besides `.` `"` `'` `:` and space.
2024-12-22 21:32:28 +00:00
a163c53a60
Refactor template & test related code ( #32938 )
...
Move some legacy code from "base" package to proper packages.
2024-12-22 15:33:19 +00:00
23687a0a71
Update i18n.go - Language Picker ( #32933 )
release-nightly / nightly-binary (push) Waiting to run
release-nightly / nightly-docker-rootful (push) Waiting to run
release-nightly / nightly-docker-rootless (push) Waiting to run
cron-translations / crowdin-pull (push) Has been skipped
2024-12-21 04:56:08 +00:00
751fe8b714
Move some errors to their own sub packages ( #32880 )
release-nightly / nightly-binary (push) Waiting to run
release-nightly / nightly-docker-rootful (push) Waiting to run
release-nightly / nightly-docker-rootless (push) Waiting to run
2024-12-20 18:05:29 +00:00
52b319bc00
Refactor pprof labels and process desc ( #32909 )
...
release-nightly / nightly-binary (push) Waiting to run
release-nightly / nightly-docker-rootful (push) Waiting to run
release-nightly / nightly-docker-rootless (push) Waiting to run
cron-translations / crowdin-pull (push) Has been skipped
* Deprecate "gopid" in log, it is not useful and requires very hacky
approach
* Remove "git.Command.SetDescription" because it is not useful and only
makes the logs too flexible
2024-12-20 12:17:14 +08:00
626b27bea5
Update go tool dependencies ( #32916 )
...
release-nightly / nightly-binary (push) Waiting to run
release-nightly / nightly-docker-rootful (push) Waiting to run
release-nightly / nightly-docker-rootless (push) Waiting to run
Update all go tool dependencies to latest version. WIP because I think
there are new gopls errors, would like to confirm them on CI first. Here
is from a local run:
```
modules/markup/markdown/goldmark.go:115:37-53: unnecessary type arguments
modules/markup/html.go:45:32-49: unnecessary type arguments
modules/markup/internal/renderinternal.go:20:33-49: unnecessary type arguments
modules/markup/common/linkify.go:27:32-49: unnecessary type arguments
modules/util/time_str.go:28:39-63: unnecessary type arguments
routers/web/repo/pull.go:704:19: impossible condition: non-nil == nil
modules/util/util_test.go:248:14-23: unused parameter: other
```
~~Backport because the `gxz` update might have security benefits.~~
2024-12-19 19:17:55 +01:00
581e52b3e7
Relax the version checking for Arch packages ( #32908 )
...
release-nightly / nightly-binary (push) Waiting to run
release-nightly / nightly-docker-rootful (push) Waiting to run
release-nightly / nightly-docker-rootless (push) Waiting to run
cron-translations / crowdin-pull (push) Has been skipped
It is mentioned in https://man.archlinux.org/man/PKGBUILD.5 : 'The
variable is not allowed to contain colons, forward slashes, hyphens, or
whitespace.'
`_` is also an allowed character, and some software in the Arch Linux
AUR uses this naming convention.
---------
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com >
2024-12-19 09:41:23 +00:00
2beaedc417
Fix Arch package metadata introduced incorrect field ( #32881 )
...
release-nightly / nightly-binary (push) Waiting to run
release-nightly / nightly-docker-rootful (push) Waiting to run
release-nightly / nightly-docker-rootless (push) Waiting to run
cron-translations / crowdin-pull (push) Has been skipped
Incorrect content was introduced while generating the index, which has
now been removed, and the missing fields have been added.

2024-12-18 15:25:05 +08:00
b945742293
Change pprof labels to be prometheus compatible ( #32865 )
...
Enables scrapping pprof endpoint for continuous profiling
Closes: https://github.com/go-gitea/gitea/issues/32854
2024-12-18 11:08:04 +08:00
2d7e6e9482
Fix various trivial problems ( #32861 )
...
release-nightly / nightly-binary (push) Waiting to run
release-nightly / nightly-docker-rootful (push) Waiting to run
release-nightly / nightly-docker-rootless (push) Waiting to run
cron-translations / crowdin-pull (push) Has been skipped
1. add/improve comments to help future readers could understand the
problem more easily.
2. add an error log to LDAP with username fallback
3. use `or` instead of `Iif` for "repo/branch_dropdown" (`Iif` was a
mistake, but it doesn't really affect the UI)
4. add `tw-font-mono` style to container digest to match dockerhub
5. fix a bug in RepoBranchTagSelector: the form is not updated when
there is no click to an item
---------
Co-authored-by: delvh <dev.lh@web.de >
2024-12-17 01:15:18 +00:00
276f43330c
Do not display attestation-manifest
and use short sha256 instead of full sha256 ( #32851 )
...
Related: #24973
Before:

After:

Index:
```json
{
"schemaVersion": 2,
"mediaType": "application/vnd.oci.image.index.v1+json",
"manifests": [
{
"mediaType": "application/vnd.oci.image.manifest.v1+json",
"digest": "sha256:5967afffdfde104ca1459286a72346baaef8b70ac153325d7a6cd85c7734ac6e",
"size": 672,
"platform": {
"architecture": "amd64",
"os": "linux"
}
},
{
"mediaType": "application/vnd.oci.image.manifest.v1+json",
"digest": "sha256:f9abfcc55320f9ff1f38eeb7dbb4bea10b29c7febfa49ccd7aab9fa02403b9f0",
"size": 672,
"platform": {
"architecture": "arm64",
"os": "linux"
}
},
{
"mediaType": "application/vnd.oci.image.manifest.v1+json",
"digest": "sha256:d70ad19d00c19e40691045cbddc3e8a5a4454c31cc454d1132b13bcaf35b6d46",
"size": 566,
"annotations": {
"vnd.docker.reference.digest": "sha256:5967afffdfde104ca1459286a72346baaef8b70ac153325d7a6cd85c7734ac6e",
"vnd.docker.reference.type": "attestation-manifest"
},
"platform": {
"architecture": "unknown",
"os": "unknown"
}
},
{
"mediaType": "application/vnd.oci.image.manifest.v1+json",
"digest": "sha256:73bc233bf4eac96a404ce3e0430b698831a4ea7050c878d5f76d1d1f133751dd",
"size": 566,
"annotations": {
"vnd.docker.reference.digest": "sha256:f9abfcc55320f9ff1f38eeb7dbb4bea10b29c7febfa49ccd7aab9fa02403b9f0",
"vnd.docker.reference.type": "attestation-manifest"
},
"platform": {
"architecture": "unknown",
"os": "unknown"
}
}
]
}
```
---------
Co-authored-by: silverwind <me@silverwind.io >
2024-12-16 10:22:49 +08:00
33e8e82c4b
Enable tenv and testifylint rules ( #32852 )
...
Enables tenv and testifylint linters
closes: https://github.com/go-gitea/gitea/issues/32842
2024-12-15 10:41:29 +00:00
d1c1e3cbcc
Fine tune ssh related comments and code ( #32846 )
...
Add more comments to explain the ssh problem,
and rename `sshConn` to `sshSession`
2024-12-15 06:07:50 +00:00
1cfb718976
Update golangci-lint to v1.62.2, fix issues ( #32845 )
...
Update it and fix new issues related to `redefines-builtin-id`
2024-12-15 02:31:07 +00:00
7616aeb2ea
In some lfs server implementations, they require the ref attribute. ( #32838 )
...
Fix : #32611
In some lfs server implementations, they require the ref attribute.
---------
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com >
2024-12-15 02:06:21 +00:00
cc5ff98e0d
Refactor markdown math render ( #32831 )
...
Add more tests
2024-12-14 13:43:05 +08:00
82c59d52ea
Add User-Agent for gitea's self-implemented lfs client. ( #32832 )
2024-12-14 03:35:19 +00:00
a66c16dc1b
Allow to fork repository into the same owner ( #32819 )
...
This feature is experimental, not fully tested, and may be changed in
the future.
It is only designed for users who really need it: set
`[repository].ALLOW_FORK_INTO_SAME_OWNER=true` in your app.ini
Doc: https://gitea.com/gitea/docs/pulls/122

2024-12-14 09:39:05 +08:00
5bc030efa2
Fix various UI bugs ( #32821 )
release-nightly / nightly-binary (push) Waiting to run
release-nightly / nightly-docker-rootful (push) Waiting to run
release-nightly / nightly-docker-rootless (push) Waiting to run
cron-translations / crowdin-pull (push) Has been skipped
2024-12-13 01:45:32 -05:00
2910f384d5
Fix misuse of PublicKeyCallback ( #32810 )
...
Only upgrading the ssh package is not enough.
2024-12-13 03:57:37 +00:00
0b8a8941a0
Fix lfs migration ( #32812 )
...
release-nightly / nightly-binary (push) Waiting to run
release-nightly / nightly-docker-rootful (push) Waiting to run
release-nightly / nightly-docker-rootless (push) Waiting to run
Fix : #32803
2024-12-12 21:36:39 +00:00
22bf2ca6ba
Make API "compare" accept commit IDs ( #32801 )
release-nightly / nightly-binary (push) Waiting to run
release-nightly / nightly-docker-rootful (push) Failing after 5m31s
release-nightly / nightly-docker-rootless (push) Failing after 5m31s
2024-12-12 08:10:09 +00:00