Giteabot and delvh
221b90d289
Add changelog for 1.20.1 ( #26015 ) ( #26056 )
...
Backport #26015 by @delvh
Co-authored-by: delvh <dev.lh@web.de >
2023-07-22 11:18:59 +02:00
Giteabot and Peter Verraedt
81f5a87eb4
Fix version in rpm repodata/primary.xml.gz ( #26009 ) ( #26048 )
...
Co-authored-by: Peter Verraedt <peter.verraedt@gmail.com >
2023-07-21 20:06:51 +00:00
Giteabot and puni9869
8b002b429d
Adding remaining enum for migration repo model type. ( #26021 ) ( #26034 )
...
Backport #26021 by @puni9869
Fixes: https://github.com/go-gitea/gitea/issues/26010
Adding remaining enum for migration repo model type.
Co-authored-by: puni9869 <80308335+puni9869@users.noreply.github.com >
2023-07-21 08:54:43 +02:00
Giteabot and Dominik Heidler
dfd371a363
RPM Registry: Show zypper commands for SUSE based distros as well ( #25981 ) ( #26020 )
...
Backport #25981 by @asdil12
After RPM is supported with https://github.com/go-gitea/gitea/pull/23380
let's show the user
how to add the repo and install the RPM via all common package managers.
Co-authored-by: Dominik Heidler <dominik@heidler.eu >
2023-07-20 21:15:47 -04:00
Giteabot and wxiaoguang
54a516e9da
Fix the route for pull-request's authors ( #26016 ) ( #26018 )
...
Backport #26016 by @wxiaoguang
Close #25906

Succeeded logs:
```
[I] router: completed GET /root/test/issues/posters?&q=%20&_=1689853025011 for [::1]:59271, 200 OK in 127.7ms @ repo/issue.go:3505(repo.IssuePosters)
[I] router: completed GET /root/test/pulls/posters?&q=%20&_=1689853968204 for [::1]:59269, 200 OK in 94.3ms @ repo/issue.go:3509(repo.PullPosters)
```
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com >
2023-07-20 13:38:12 +00:00
Giteabot
ac129d4b4c
Correctly refer to dev tags as nightly in the docker docs ( #26004 ) ( #26019 )
...
Backport #26004 by @jolheiser
As title, `dev` tags are no longer used since we switched to `nightly`
Signed-off-by: jolheiser <john.olheiser@gmail.com >
2023-07-20 21:03:40 +08:00
Giteabot and wxiaoguang
4d5e3b9372
Fix env config parsing for "GITEA____APP_NAME" ( #26001 ) ( #26013 )
...
Backport #26001 by @wxiaoguang
Regression of #24832
Fix the bug and add a test for it
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com >
2023-07-20 11:56:36 +02:00
Giteabot and silverwind
1ba0baa030
Fix commit status color on dashboard repolist ( #25993 ) ( #25998 )
...
Backport #25993 by @silverwind
Followup to https://github.com/go-gitea/gitea/pull/25935 which has
missed to change the icon on the repolist because the logic is not
shared with templates.
Co-authored-by: silverwind <me@silverwind.io >
2023-07-19 23:24:04 +00:00
28e8c691a6
avoid hard-coding height in language dropdown menu ( #25986 ) ( #25997 )
...
Backport #25986 by @earl-warren
This commit removes the hard-coded height of 500px, using that as a
max-height instead. The height of items in the dropdown menu, assuming a
default font size of 16px, is 36px, so the old CSS would cause overly
large dropdown menus in instances where less than 14 languages are
offered.
Refs: https://codeberg.org/forgejo/forgejo/pulls/1000
Co-authored-by: Earl Warren <109468362+earl-warren@users.noreply.github.com >
Co-authored-by: rome-user <rome-user@noreply.codeberg.org >
2023-07-20 01:05:22 +02:00
Giteabot and Earl Warren
f81a612eb1
parseScope with owner/repo always sets owner to zero ( #25987 ) ( #25989 )
...
Backport #25987 by @earl-warren
Refs: https://codeberg.org/forgejo/forgejo/pulls/1001
Co-authored-by: Earl Warren <109468362+earl-warren@users.noreply.github.com >
2023-07-19 22:57:17 +08:00
Giteabot and wxiaoguang
ee47face12
Update path related documents ( #25417 ) ( #25982 )
...
Backport #25417 by @wxiaoguang
Update WorkPath/WORK_PATH related documents, remove out-dated
information.
Remove "StaticRootPath" on the admin config display page, because few
end user really need it, it only causes misconfiguration.

Co-authored-by: wxiaoguang <wxiaoguang@gmail.com >
2023-07-19 09:48:54 +00:00
864bdd0ac8
Make pending commit status yellow again ( #25935 ) ( #25968 )
...
Backport #25935 by @silverwind
With the introduction of Actions, the pending commit icon has changed
from yellow to grey for Drone integrations which never set the "running"
status, so it stays in "pending" until completion.
I find it better to have this icon colored like on 1.19. Now both the
"pending" and "running" icons look the same, but I guess we could add an
animation to the "running" state similar to GitHub has to it later.
Before:
<img width="339" alt="Screenshot 2023-07-17 at 19 14 19"
src="https://github.com/go-gitea/gitea/assets/115237/2f4886e4-74fd-42ea-b59e-9af8f141bf1f ">
After:
<img width="335" alt="Screenshot 2023-07-17 at 19 14 30"
src="https://github.com/go-gitea/gitea/assets/115237/53189642-e72d-47f6-9cbe-f14eda28f730 ">
Also, it matches GH's icon:
<img width="466" alt="image"
src="https://github.com/go-gitea/gitea/assets/115237/5804ff90-d223-4a3c-8093-7a9abbaacf87 ">
Co-authored-by: silverwind <me@silverwind.io >
Co-authored-by: delvh <dev.lh@web.de >
2023-07-19 06:43:41 +00:00
Giteabot and Jason Song
037a3f0d8c
Show the mismatched ROOT_URL warning on the sign-in page if OAuth2 is enabled ( #25947 ) ( #25972 )
...
Backport #25947 by @wolfogre
Since OAuth2 will callback the root URL, if the user starts signing in
from a wrong host, Gitea will return 500 because it cannot find the
session.
<details>
<summary>How to reproduce</summary>
<img width="901" alt="image"
src="https://github.com/go-gitea/gitea/assets/9418365/2c2e255c-e13e-4a11-9be7-b226bee54920 ">
<img width="1014" alt="image"
src="https://github.com/go-gitea/gitea/assets/9418365/b31cfcf6-a320-483d-9ce5-ba8562f065e1 ">
</details>
So show the mismatched ROOT_URL warning on the sign-in page if OAuth2 is
enabled.
<img width="1015" alt="image"
src="https://github.com/go-gitea/gitea/assets/9418365/99e80b17-c790-49a3-bbf2-2bd9396a7daa ">
Co-authored-by: Jason Song <i@wolfogre.com >
2023-07-19 04:35:16 +00:00
Giteabot and wxiaoguang
227c3b67e0
Fix SSPI auth panic ( #25955 ) ( #25969 )
...
Backport #25955 by @wxiaoguang
Try to fix #25952
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com >
2023-07-18 22:28:06 +00:00
Giteabot and Jason Song
b7d054e4b5
Ignore runs-on with expressions when warning no matched runners ( #25917 ) ( #25933 )
...
Backport #25917 by @wolfogre
Fix #25905
Co-authored-by: Jason Song <i@wolfogre.com >
2023-07-18 06:40:28 +00:00
Giteabot
d032500687
Make environment-to-ini work with INSTALL_LOCK=true ( #25926 ) ( #25937 )
...
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com >
fix #25924
2023-07-17 18:28:54 +00:00
Giteabot and yp05327
9159964ada
Avoid opening/closing PRs which are already merged ( #25883 ) ( #25903 )
...
Backport #25883 by @yp05327
We can select PRs to open/close them by one click, but we forgot to
check whether it is merged.
You can get an opening merged PR:

You can confirm this in:
https://try.gitea.io/yp05327/testrepo/pulls/5
Co-authored-by: yp05327 <576951401@qq.com >
2023-07-17 12:14:22 +00:00
Giteabot and wxiaoguang
9369b38315
Skip unuseful error message in dev mode when watching local filesystem ( #25919 ) ( #25927 )
...
Backport #25919 by @wxiaoguang
Before, in dev mode, there might be some error logs like:
```
2023/07/17 13:54:51 ...s/assetfs/layered.go:221:WatchLocalChanges() [E] Unable to watch directory .: lstat /data/work/gitea/custom/templates: no such file or directory
```
Because there is no "custom/templates" directory.
After: ignore such error, no such error message anymore.
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com >
2023-07-17 10:26:29 +00:00
Giteabot and KN4CK3R
6e82d0bb7c
Add shutting down notice ( #25920 ) ( #25922 )
...
Backport #25920 by @KN4CK3R
Got the same problem as #25915 when updating an instance. The
`log.Fatal` should have been marked as breaking in #23911 .
This PR adds a notice that the system is shutting down because of the
deprecated setting.
Co-authored-by: KN4CK3R <admin@oldschoolhack.me >
2023-07-17 09:44:10 +00:00
Giteabot and yp05327
36b9a86bd8
Fix incorrect milestone count when provide a keyword ( #25880 ) ( #25904 )
...
Backport #25880 by @yp05327
You can confirm this issue in:
https://try.gitea.io/yp05327/testrepo/milestones?state=open&q=a
There's no milestone, but the count is 1.

Co-authored-by: yp05327 <576951401@qq.com >
2023-07-17 11:12:59 +02:00
Giteabot and hiifong
de8127e78b
fix incorrect repo url when changed the case of ownername ( #25733 ) ( #25881 )
...
Backport #25733 by @hiifong
When only the casing of the username changes, update the owner name of the repo,
and keep the original logic consistent with other conditions.
example: assume your username is `gitea`, lowercase username is `gitea` too,
repo URL is `.../gitea/{repo}`.
You change your username to `Gitea`, `GiTea` or something like that,
as long as the lowercase username is still `gitea`, the repo URL remained `.../gitea/{repo}`.
this pr keeps the new username consistent with the repo URL.
Before:


After:


Co-authored-by: hiifong <i@hiif.ong >
2023-07-15 19:47:24 +02:00
Giteabot and sebastian-sauer
186f07bbf7
Make add line comment buttons focusable ( #25894 ) ( #25896 )
...
Backport #25894 by @sebastian-sauer
Use a real button and add an aria-label.
Additionally, show the button whenever it is focused.
See https://codeberg.org/forgejo/forgejo/issues/998 for explanation.
Our handling of this button is now equal to that of GitHub.
Nothing has changed visually.
Co-authored-by: sebastian-sauer <sauer.sebastian@gmail.com >
2023-07-15 12:18:49 +02:00
Giteabot and KN4CK3R
45b1f4dd3b
Add support for different Maven POM encoding ( #25873 ) ( #25890 )
...
Backport #25873 by @KN4CK3R
Fixes #25853
- Maven POM files aren't always UTF-8 encoded.
- Reject the upload of unparsable POM files
Co-authored-by: KN4CK3R <admin@oldschoolhack.me >
2023-07-14 10:27:15 +00:00
Giteabot and yp05327
026e745b9e
Fix incorrect release count ( #25879 ) ( #25887 )
...
Backport #25879 by @yp05327
Release count is not correct:
https://try.gitea.io/yp05327/testrepo/tags

https://try.gitea.io/yp05327/testrepo/releases

https://try.gitea.io/yp05327/testrepo/releases/tag/testtag

We already have correct release count, no need to calculate it again.
https://github.com/go-gitea/gitea/blob/c5e187c389b35b9e080a3187b93a775a3c81e585/modules/context/repo.go#L547
Co-authored-by: yp05327 <576951401@qq.com >
2023-07-14 09:32:43 +00:00
c334be8284
Fix empty project displayed in issue sidebar ( #25802 ) ( #25854 )
...
Backport #25802 by @yp05327
You can confirm this issue in
https://try.gitea.io/yp05327/testrepo/issues/2
Before:

After:

This issue comes from the change in #25468 .
`LoadProject` will always return at least one record, so we use
`ProjectID` to check whether an issue is linked to a project in the old
code.
As other `issue.LoadXXX` functions, we need to check the return value
from `xorm.Session.Get`.
In recent unit tests, we only test `issueList.LoadAttributes()` but
don't test `issue.LoadAttributes()`. So I added a new test for
`issue.LoadAttributes()` in this PR.
Co-authored-by: yp05327 <576951401@qq.com >
Co-authored-by: Denys Konovalov <privat@denyskon.de >
2023-07-12 19:07:03 +02:00
353dcc5ad4
Fix the error message when the token is incorrect ( #25701 ) ( #25836 )
...
Backport #25701 by @CaiCandong
we refactored `userIDFromToken` for the token parsing part into a new
function `parseToken`. `parseToken` returns the string `token` from
request, and a boolean `ok` representing whether the token exists or
not. So we can distinguish between token non-existence and token
inconsistency in the `verfity` function, thus solving the problem of no
proper error message when the token is inconsistent.
close #24439
related #22119
Co-authored-by: caicandong <50507092+CaiCandong@users.noreply.github.com >
Co-authored-by: Jason Song <i@wolfogre.com >
2023-07-12 10:18:27 +00:00
Giteabot and wxiaoguang
abe9c641ce
Show correct SSL Mode on "install page" ( #25818 ) ( #25838 )
...
Backport #25818 by @wxiaoguang
Fix #25817

Co-authored-by: wxiaoguang <wxiaoguang@gmail.com >
2023-07-12 02:01:38 -04:00
Giteabot and yp05327
052e65e63f
Fix incorrect oldest sort in project list ( #25806 ) ( #25835 )
...
Backport #25806 by @yp05327
sort type `oldest` should be `Asc`.
Added a test for this.
I see we have `SearchOrderBy` in db model, but we are using many
different ways to define the sort type.
~Maybe we can improve this later.~
↑ Improved in this PR
Co-authored-by: yp05327 <576951401@qq.com >
2023-07-12 13:22:17 +08:00
Giteabot and Lunny Xiao
2b79d3fd52
For API attachments, use API URL ( #25639 ) ( #25814 )
...
Backport #25639 by @lunny
Fix #25257
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com >
2023-07-10 12:56:16 +00:00
Giteabot and wxiaoguang
a1bc2aa05e
Avoid amending the Rebase and Fast-forward merge if there is no message template ( #25779 ) ( #25809 )
...
Backport #25779 by @wxiaoguang
Related #22669 . Close #25177
After the fix:

Co-authored-by: wxiaoguang <wxiaoguang@gmail.com >
2023-07-10 10:23:54 +00:00
Giteabot and wxiaoguang
d713cf6150
Fix WORK_DIR for docker (root) image ( #25738 ) ( #25811 )
...
Backport #25738 by @wxiaoguang
Fix #25726
#17846 chose an incorrect WORK_DIR path for docker root image.
Gitea's work-path was already used as the base path for various paths
(like AppDataPath), so, the work-path should be mounted to a volume in a
docker image.
Now, for docker root image, it's unavoidable to mix the
WorkPath/CustomPath/AppDataPath in the same directory ("/data/gitea"),
because some of them have already been mixed.
Some directories in the screenshot are for "CustomPath" , while others
are for "AppDataPath", due to the technical debts in old code:
```
CUSTOM_PATH="/data/gitea"
APP_DATA_PATH = /data/gitea
```
<details>

</details>
This PR is breaking but this is the only way at the moment to avoid
users losing their data accidently
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com >
2023-07-10 10:54:16 +02:00
Giteabot and KN4CK3R
372b622c2b
Revert package access change from #23879 ( #25707 ) ( #25785 )
...
Backport #25707 by @KN4CK3R
Fixes (?) #25538
Fixes https://codeberg.org/forgejo/forgejo/issues/972
Regression #23879
#23879 introduced a change which prevents read access to packages if a
user is not a member of an organization.
That PR also contained a change which disallows package access if the
team unit is configured with "no access" for packages. I don't think
this change makes sense (at the moment). It may be relevant for private
orgs. But for public or limited orgs that's useless because an
unauthorized user would have more access rights than the team member.
This PR restores the old behaviour "If a user has read access for an
owner, they can read packages".
Co-authored-by: KN4CK3R <admin@oldschoolhack.me >
2023-07-09 21:00:42 +00:00
Giteabot and KN4CK3R
06bcdfe77a
Remove unused code ( #25734 ) ( #25788 )
...
Backport #25734 by @KN4CK3R
The method is only used in the test. Found it because I changed the
fixtures and had a hard time fixing this test. My revenge is deleting
it.
Co-authored-by: KN4CK3R <admin@oldschoolhack.me >
2023-07-09 19:47:58 +00:00
Giteabot and wxiaoguang
a5a3c81412
Fix notification list bugs ( #25781 ) ( #25787 )
...
Backport #25781 by @wxiaoguang
Fix #25627
1. `ctx.Data["Link"]` should use relative URL but not AppURL
2. The `data-params` is incorrect because it doesn't contain "page". JS
can simply use "window.location.search" to construct the AJAX URL
3. The `data-xxx` and `id` in notification_subscriptions.tmpl were
copied&pasted, they don't have affect.
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com >
2023-07-09 19:15:00 +00:00
ea2c9de3c4
Test if container blob is accessible before mounting ( #22759 ) ( #25784 )
...
Backport #22759 by @KN4CK3R
related #16865
This PR adds an accessibility check before mounting container blobs.
Co-authored-by: KN4CK3R <admin@oldschoolhack.me >
Co-authored-by: techknowlogick <techknowlogick@gitea.io >
Co-authored-by: silverwind <me@silverwind.io >
2023-07-09 12:00:04 +00:00
Giteabot and leavesster
68a3961bf1
docs: rootless docker ssh's default port is 2222 ( #25771 ) ( #25772 )
...
Backport #25771 by @leavesster
---
according `docker/rootless/usr/local/bin/docker-setup.sh` , in rootless
docker setup, ssh port is 2222.
and mysql database case should port same as PostgreSQL port
Co-authored-by: leavesster <11785335+leavesster@users.noreply.github.com >
2023-07-09 15:45:42 +08:00
Giteabot and Maxim Slipenko
91dadedddf
Translate untranslated string in issues list ( #25759 ) ( #25761 )
...
Backport #25759 by @Maks1mS
Co-authored-by: Maxim Slipenko <no-reply@maxim.slipenko.com >
2023-07-07 23:04:08 +00:00
Giteabot and hiifong
32eaba1b40
Hide add file button for pull mirrors ( #25748 ) ( #25751 )
...
Backport #25748 by @hiifong
I think hiding the add file button for mirror repositories that can keep
the ui clean.
Before:

After:

Co-authored-by: hiifong <i@hiif.ong >
2023-07-07 14:12:59 +00:00
e595dfeec7
Allow/fix review (approve/reject) of empty PRs ( #25690 ) ( #25732 )
...
Backport #25690 by @sebastian-sauer
gitea allows to create empty PRs.
Currently when you need approvals for a merge, you have to manually add
/files to the url to get to the files tab to approve / reject the PR.
This PR allows to open the files tab via the normal tab / link and then
fixes the layout of the files tab.
**Screenshots:**
Before:

After:

Co-authored-by: sebastian-sauer <sauer.sebastian@gmail.com >
Co-authored-by: silverwind <me@silverwind.io >
2023-07-06 19:34:41 +00:00
Giteabot and Jason Song
03cacf971e
Check ctx.Written() for GetActionIssue ( #25698 ) ( #25711 )
...
Backport #25698 by @wolfogre
Fix #25697 .
Just avoid panic, maybe there's another bug to trigger this case.
Co-authored-by: Jason Song <i@wolfogre.com >
2023-07-06 21:04:26 +02:00
68e0c802f7
Show correct naming for 1 comment ( #25704 ) ( #25712 )
...
Backport #25704 by @earl-warren
- Resolves https://codeberg.org/forgejo/forgejo/issues/948
Co-authored-by: Earl Warren <109468362+earl-warren@users.noreply.github.com >
Co-authored-by: Gusted <postmaster@gusted.xyz >
2023-07-06 16:04:13 +00:00
Giteabot and Jason Song
09668b2e2e
Correct permissions for .ssh and authorized_keys ( #25721 ) ( #25730 )
...
Backport #25721 by @wolfogre
Set the correct permissions on the .ssh directory and authorized_keys
file, or sshd will refuse to use them and lead to clone/push/pull
failures.
It could happen when users have copied their data to a new volume and
changed the file permission by accident, and it would be very hard to
troubleshoot unless users know how to check the logs of sshd which is
started by s6.
Co-authored-by: Jason Song <i@wolfogre.com >
2023-07-06 11:02:56 -04:00
Giteabot and Lunny Xiao
04eea29ecb
Fix tags header and pretty format numbers ( #25624 ) ( #25694 )
...
Backport #25624 by @lunny
This casused by #23465
Before
release disabled
<img width="1320" alt="图片"
src="https://github.com/go-gitea/gitea/assets/81045/190a1c81-daa5-41bc-91ac-c9a0bf629b5f ">
release enabled
<img width="1320" alt="图片"
src="https://github.com/go-gitea/gitea/assets/81045/a0372c31-727c-4ee0-a6b9-30e502498d90 ">
After
release disabled
<img width="1304" alt="图片"
src="https://github.com/go-gitea/gitea/assets/81045/a747ea80-a3d9-4792-8f6d-e8955da78b9e ">
release enabled
<img width="1290" alt="图片"
src="https://github.com/go-gitea/gitea/assets/81045/7c0bc43a-9149-4148-859d-35839aeb60ca ">
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com >
2023-07-05 07:08:16 +00:00
Giteabot and silverwind
511be9fe6e
Fix position of org follow button ( #25688 ) ( #25692 )
...
Backport #25688 by @silverwind
This has recently regressed it seems. Put it back into same position as
https://github.com/go-gitea/gitea/pull/24345 .
Before:
<img width="1246" alt="image"
src="https://github.com/go-gitea/gitea/assets/115237/bb410c29-5539-4dad-8351-8da8470f7091 ">
After:
<img width="1236" alt="Screenshot 2023-07-04 at 21 19 13"
src="https://github.com/go-gitea/gitea/assets/115237/072e0e83-defd-484d-8861-33d73fa0e446 ">
Co-authored-by: silverwind <me@silverwind.io >
2023-07-05 08:31:12 +02:00
Giteabot and delvh
4e310133f9
Prevent duplicate image loading ( #25675 ) ( #25684 )
...
Backport #25675 by @delvh
Regression of #25672 .
Co-authored-by: delvh <dev.lh@web.de >
2023-07-04 14:49:39 +00:00
Giteabot and Zettat123
5510ed34f1
Fix the nil pointer when assigning issues to projects ( #25665 ) ( #25677 )
...
Backport #25665 by @Zettat123
Fixes #25649
Caused by #25468
Co-authored-by: Zettat123 <zettat123@gmail.com >
2023-07-04 10:59:01 +00:00
Giteabot and HesterG
1f90376041
Fix show more for image on diff page ( #25672 ) ( #25673 )
...
Backport #25672 by @HesterG
Right now when clicking on loadmore on files change page, if the loaded
content is image, it will be always in load status:
https://github.com/go-gitea/gitea/assets/17645053/39e449b6-067a-474c-9443-9dd98d5bbfe2
This PR fixes this by adding `initImageDiff ` to `onShowMoreFiles `
After:
https://github.com/go-gitea/gitea/assets/17645053/87bbb13e-0064-4a6e-a7ad-0f0060eb8bff
Co-authored-by: HesterG <hestergong@gmail.com >
2023-07-04 04:44:45 -04:00
0af6542a34
Add unit test for repository collaboration ( #25640 ) ( #25658 )
...
Backport #25640 by @earl-warren
- Add a few extra test cases and test functions for the collaboration
model to get everything covered by tests (except for error handling, as
we cannot suddenly mock errors from the database).
```
-> % go tool cover -func=coverage.out | grep "code.gitea.io/gitea/models/repo/collaboration.go"
```
Before:
```
code.gitea.io/gitea/models/repo/collaboration.go:28: init 100.0%
code.gitea.io/gitea/models/repo/collaboration.go:39: GetCollaborators 61.5%
code.gitea.io/gitea/models/repo/collaboration.go:65: CountCollaborators 0.0%
code.gitea.io/gitea/models/repo/collaboration.go:70: GetCollaboration 0.0%
code.gitea.io/gitea/models/repo/collaboration.go:83: IsCollaborator 100.0%
code.gitea.io/gitea/models/repo/collaboration.go:87: getCollaborations 42.9%
code.gitea.io/gitea/models/repo/collaboration.go:102: ChangeCollaborationAccessMode 77.8%
code.gitea.io/gitea/models/repo/collaboration.go:141: IsOwnerMemberCollaborator 0.0%
```
After:
```
code.gitea.io/gitea/models/repo/collaboration.go:28: init 100.0%
code.gitea.io/gitea/models/repo/collaboration.go:39: GetCollaborators 61.5%
code.gitea.io/gitea/models/repo/collaboration.go:65: CountCollaborators 100.0%
code.gitea.io/gitea/models/repo/collaboration.go:70: GetCollaboration 100.0%
code.gitea.io/gitea/models/repo/collaboration.go:83: IsCollaborator 100.0%
code.gitea.io/gitea/models/repo/collaboration.go:87: getCollaborations 100.0%
code.gitea.io/gitea/models/repo/collaboration.go:102: ChangeCollaborationAccessMode 83.3%
code.gitea.io/gitea/models/repo/collaboration.go:141: IsOwnerMemberCollaborator 87.5%
```
Co-authored-by: Gusted <postmaster@gusted.xyz >
Reviewed-on: https://codeberg.org/forgejo/forgejo/pulls/825
Co-authored-by: Earl Warren <109468362+earl-warren@users.noreply.github.com >
Co-authored-by: Gusted <postmaster@gusted.xyz >
Co-authored-by: Gusted <gusted@noreply.codeberg.org >
Co-authored-by: silverwind <me@silverwind.io >
2023-07-04 06:29:43 +00:00
Giteabot and Lunny Xiao
69bdcf41f3
Log the real reason when authentication fails (but don't show the user) ( #25414 ) ( #25660 )
...
Backport #25414 by @lunny
Fix #24498
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com >
2023-07-03 19:26:36 -04:00
Giteabot and wxiaoguang
e610b0389a
Fix UI misalignment on user setting page ( #25629 ) ( #25656 )
...
Backport #25629 by @wxiaoguang
Fix #25628
Diff with ignoring space:
https://github.com/go-gitea/gitea/pull/25629/files?diff=unified&w=1
The "modal" shouldn't appear between "ui attached segment", otherwise
these segments lose margin-top.
After the fix:
<details>




</details>
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com >
2023-07-03 21:16:58 +00:00
Giteabot and Lunny Xiao
64ed262e18
Fix bug when change user name ( #25637 ) ( #25646 )
...
Backport #25637 by @lunny
Fix #25621
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com >
2023-07-03 14:23:35 +03:00
Giteabot and derelm
d8a59d5f12
use css on labels ( #25626 ) ( #25636 )
...
Backport #25626 by @derelm
Changes html to use CSS label class similar to
`templates/shared/actions/runner_list.tmpl`
Before:

After:

List view (for reference - unchanged):

Co-authored-by: derelm <465155+derelm@users.noreply.github.com >
2023-07-03 12:25:16 +08:00
Giteabot and sebastian-sauer
1ddfe03131
Use AfterCommitId to get commit for Viewed functionality ( #25529 ) ( #25612 )
...
Backport #25529 by @sebastian-sauer
the PullHeadCommitID is not always available when the PR is merged.
Not sure if this is the best solution but in my simple tests it looks
like this fixes the problem - happy to get any feedback.
hopefully fixes https://github.com/go-gitea/gitea/issues/24813
Co-authored-by: sebastian-sauer <sauer.sebastian@gmail.com >
2023-07-01 07:56:56 +08:00
Giteabot and Jason Song
24cf06592e
Restrict [actions].DEFAULT_ACTIONS_URL to only github or self ( #25581 ) ( #25604 )
...
Backport #25581 by @wolfogre
Resolve #24789
## ⚠️ BREAKING ⚠️
Before this, `DEFAULT_ACTIONS_URL` cound be set to any custom URLs like
`https://gitea.com ` or `http://your-git-server,https://gitea.com `, and
the default value was `https://gitea.com `.
But now, `DEFAULT_ACTIONS_URL` supports only
`github`(`https://github.com `) or `self`(the root url of current Gitea
instance), and the default value is `github`.
If it has configured with a URL, an error log will be displayed and it
will fallback to `github`.
Actually, what we really want to do is always make it
`https://github.com `, however, this may not be acceptable for some
instances of internal use, so there's extra support for `self`, but no
more, even `https://gitea.com `.
Please note that `uses: https://xxx/yyy/zzz ` always works and it does
exactly what it is supposed to do.
Although it's breaking, I belive it should be backported to `v1.20` due
to some security issues.
Follow-up on the runner side:
- https://gitea.com/gitea/act_runner/pulls/262
- https://gitea.com/gitea/act/pulls/70
Co-authored-by: Jason Song <i@wolfogre.com >
2023-06-30 07:53:00 +00:00
0b6f7fb607
read-only checkboxes don't appear and don't entirely act the way one might expect ( #25573 ) ( #25602 )
...
Backport #25573 by @saegl5
This pull request fades read-only checkboxes and checkmark, and it makes
the checkboxes act more read-only/disabled by not changing the
border-color when clicked.
Examples using light mode:
| Before | After |
| - | - |
| 
| 
|
| 
| 
|
| | read-only checkboxes and checkmark are faded<br>and the checkboxes
act more read-only/disabled |
Fixes/Closes/Resolves #25076
Co-authored-by: Ed Silkworth <ed.silkworth@icloud.com >
Co-authored-by: silverwind <me@silverwind.io >
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com >
2023-06-29 22:53:43 +00:00
Giteabot and Zettat123
12aca3ef20
Add documentation about supported workflow trigger events ( #25582 ) ( #25589 )
...
Backport #25582 by @Zettat123
Right now Gitea doesn't support all [Events that trigger
workflows](https://docs.github.com/en/actions/using-workflows/events-that-trigger-workflows ).
This PR lists the supported events to help users write workflow files.
Co-authored-by: Zettat123 <zettat123@gmail.com >
2023-06-29 14:51:46 +02:00
Giteabot and silverwind
2390a46d0f
Reduce table padding globally ( #25568 ) ( #25577 )
...
Backport #25568 by @silverwind
Fomantic's tables have too much padding. Reduce it so we have more
information density in them. Especially the admin tables need this
because they are bursting already because of column count.
## Admin repolist before and after
<img width="909" alt="Screenshot 2023-06-28 at 20 27 55"
src="https://github.com/go-gitea/gitea/assets/115237/954c925c-8db5-47ce-ae51-a2168b857014 ">
<img width="897" alt="Screenshot 2023-06-28 at 20 36 03"
src="https://github.com/go-gitea/gitea/assets/115237/0bddc09a-9117-48b3-a17e-3d34c58d8d3d ">
## Other tables
<img width="1230" alt="Screenshot 2023-06-28 at 20 36 22"
src="https://github.com/go-gitea/gitea/assets/115237/38f555b6-a7ce-416a-9f1f-706eaf18863b ">
<img width="1236" alt="Screenshot 2023-06-28 at 20 26 37"
src="https://github.com/go-gitea/gitea/assets/115237/82b2878e-358c-4dc2-a6b4-c66e43cd2dfb ">
<img width="1231" alt="Screenshot 2023-06-28 at 20 59 30"
src="https://github.com/go-gitea/gitea/assets/115237/c6a92e55-a3a3-4c80-9a0d-50aebb49886c ">
Files table is unaffected because it has custom padding already.
Co-authored-by: silverwind <me@silverwind.io >
2023-06-29 09:24:02 +00:00
Giteabot and HesterG
51b6a78791
Fix milestones deletion ( #25583 ) ( #25584 )
...
Backport #25583 by @HesterG
Close #25557
Fix regression from #25315
`data-id` is still needed for deleting milestone.
Co-authored-by: HesterG <hestergong@gmail.com >
2023-06-29 08:52:05 +00:00
Giteabot and Jason Song
8981f6d0fc
Fix content holes in Actions task logs file ( #25560 ) ( #25566 )
...
Backport #25560 by @wolfogre
Fix #25451 .
Bugfixes:
- When stopping the zombie or endless tasks, set `LogInStorage` to true
after transferring the file to storage. It was missing, it could write
to a nonexistent file in DBFS because `LogInStorage` was false.
- Always update `ActionTask.Updated` when there's a new state reported
by the runner, even if there's no change. This is to avoid the task
being judged as a zombie task.
Enhancement:
- Support `Stat()` for DBFS file.
- `WriteLogs` refuses to write if it could result in content holes.
Co-authored-by: Jason Song <i@wolfogre.com >
2023-06-28 23:39:23 +00:00
Giteabot and Georg Dangl
b2b5c80cb2
Use correct response code in push mirror creation response in v1_json.tmpl ( #25476 ) ( #25571 )
...
Backport #25476 by @GeorgDangl
In the process of doing a bit of automation via the API, we've
discovered a _small_ issue in the Swagger definition. We tried to create
a push mirror for a repository, but our generated client raised an
exception due to an unexpected status code.
When looking at this function:
https://github.com/go-gitea/gitea/blob/3c7f5ed7b5bff347198cbb26492e6354ea42733b/routers/api/v1/repo/mirror.go#L236-L240
We see it defines `201 - Created` as response:
https://github.com/go-gitea/gitea/blob/3c7f5ed7b5bff347198cbb26492e6354ea42733b/routers/api/v1/repo/mirror.go#L260-L262
But it actually returns `200 - OK`:
https://github.com/go-gitea/gitea/blob/3c7f5ed7b5bff347198cbb26492e6354ea42733b/routers/api/v1/repo/mirror.go#L373
So I've just updated the Swagger definitions to match the code😀
Co-authored-by: Georg Dangl <10274404+GeorgDangl@users.noreply.github.com >
2023-06-28 19:00:56 -04:00
Giteabot and Zettat123
77db40e084
Fix bugs related to notification endpoints ( #25548 ) ( #25562 )
...
Backport #25548 by @Zettat123
This PR
- fixes #25545
- fixes two incorrect `reqToken()` in `/notifications` endpoints (caused
by #24767 )
Co-authored-by: Zettat123 <zettat123@gmail.com >
2023-06-28 16:24:48 +00:00
Giteabot and wxiaoguang
7222bac4e3
Align language menu icon and fit the footer area ( #25556 ) ( #25563 )
...
Backport #25556 by @wxiaoguang
Close #25551
## Before

## After

----

Co-authored-by: wxiaoguang <wxiaoguang@gmail.com >
2023-06-28 11:51:24 -04:00
Giteabot and KN4CK3R
102dcfa3a0
Change Regenerate Secret button display ( #25534 ) ( #25541 )
...
Backport #25534 by @KN4CK3R
Fixes #25527
Preview:

Co-authored-by: KN4CK3R <admin@oldschoolhack.me >
2023-06-27 20:14:58 +00:00
614d6df2d8
Fix admin-dl-horizontal ( #25512 ) ( #25535 )
...
Backport #25512 by @wxiaoguang


Co-authored-by: wxiaoguang <wxiaoguang@gmail.com >
Co-authored-by: HesterG <hestergong@gmail.com >
Co-authored-by: silverwind <me@silverwind.io >
2023-06-27 17:06:36 +00:00
Giteabot and HesterG
345a25d016
Fix rerun icon on action view component ( #25531 ) ( #25536 )
...
Backport #25531 by @HesterG
Right now rerun icon on action view component will not be seen when
duration text length is long, because the wrapper `job-brief-info` has a
fixed width, and the svg is squeezed. The way to fix this in this PR is
to change width to `fit-content` and exchange position of duration text
and rerun svg.
Before (rerun svg not shown on hover):
<img width="1401" alt="Screen Shot 2023-06-27 at 12 53 41"
src="https://github.com/go-gitea/gitea/assets/17645053/bb3f62ec-8c56-4dbc-96f1-718b50426d91 ">
After:
<img width="1409" alt="Screen Shot 2023-06-27 at 12 50 59"
src="https://github.com/go-gitea/gitea/assets/17645053/620aa02c-2326-408d-a763-453f48f42c40 ">
Co-authored-by: HesterG <hestergong@gmail.com >
2023-06-27 12:28:14 -04:00
e8a7cd4a1d
Fix input line-height cutting off g ( #25334 ) ( #25533 )
...
Backport #25334 by @hiifong
Fix the incomplete display of input text
Before:


After:


Co-authored-by: hiifong <i@hiif.ong >
Co-authored-by: silverwind <me@silverwind.io >
2023-06-27 11:31:18 +02:00
9d69a4758e
Add Adopt repository event and handler ( #25497 ) ( #25518 )
...
Backport #25497 by @lunny
Fix #14304
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com >
Co-authored-by: delvh <dev.lh@web.de >
Co-authored-by: KN4CK3R <admin@oldschoolhack.me >
2023-06-26 20:09:07 +00:00
Giteabot and wxiaoguang
53747a58a0
Clarify the reason why the user can't add a new email if there is a pending activation ( #25509 ) ( #25514 )
...
Backport #25509 by @wxiaoguang

Co-authored-by: wxiaoguang <wxiaoguang@gmail.com >
2023-06-26 17:28:48 +08:00
Giteabot and wxiaoguang
00ba826360
Fix CLI sub-command handling ( #25501 ) ( #25517 )
...
Backport #25501 by @wxiaoguang
A regression of #25330 : The nil "Action" should be treated as "help"
In old releases: `./gitea admin` show helps
After #25330 : `./gitea admin` panics (although the code returned `nil`
if action is nil, but Golang's quirk is: nil in interface is not nil)
With this PR: `./gitea admin` shows helps as the old releases.
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com >
2023-06-26 16:41:52 +08:00
Giteabot
9bbb4d8d6d
Improve loadprojects for issue list ( #25468 ) ( #25493 )
2023-06-26 02:06:58 +00:00
Giteabot and wxiaoguang
85bad22ff8
Fine tune "dropdown button" icon ( #25442 ) ( #25499 )
...
Backport #25442 by @wxiaoguang

----

Co-authored-by: wxiaoguang <wxiaoguang@gmail.com >
2023-06-25 14:35:26 +08:00
Giteabot and wxiaoguang
71d2a6a41a
Use InitWorkPathAndCfgProvider for environment-to-ini to avoid unnecessary checks ( #25480 ) ( #25488 )
...
Backport #25480 by @wxiaoguang
Fix #25481
The `InitWorkPathAndCommonConfig` calls `LoadCommonSettings` which does
many checks like "current user is root or not".
Some commands like "environment-to-ini" shouldn't do such check, because
it might be run with "root" user at the moment (eg: the docker's setup
script)
ps: in the future, the docker's setup script should be improved to avoid
Gitea's command running with "root"
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com >
2023-06-24 14:04:50 +00:00
Giteabot
2cd9d6b3f9
Fix wrong warn messages in migration steps ( #25475 ) ( #25487 )
2023-06-24 17:51:26 +08:00
Giteabot and wxiaoguang
51789ba12d
Improve wiki sidebar and TOC ( #25460 ) ( #25477 )
...
Backport #25460 by @wxiaoguang
Close #20976
Close #20975
1. Fix the bug: the TOC in footer was incorrectly rendered as main
content's TOC
2. Fix the layout: on mobile, the TOC is put above the main content,
while the sidebar is put below the main content
3. Auto collapse the TOC on mobile
ps: many styles of "wiki.css" are moved from old css files, so leave
nits to following PRs.
### for desktop

### for mobile

### other changed pages
<details>


</details>
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com >
2023-06-24 10:16:15 +08:00
Giteabot and Lunny Xiao
b0de3d08b8
Fix repo search broken because of profile page added ( #25455 ) ( #25467 )
...
Backport #25455 by @lunny
Fix #25433
Caused by #23260
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com >
2023-06-23 15:48:35 +02:00
Giteabot and wxiaoguang
2e64449de7
Make "dismiss" content shown correctly ( #25461 ) ( #25465 )
...
Backport #25461 by @wxiaoguang
Close #25127

Co-authored-by: wxiaoguang <wxiaoguang@gmail.com >
2023-06-23 11:04:15 +00:00
Giteabot and Jason Song
203fe2841d
Fix Permission in API returned repository struct ( #25388 ) ( #25441 )
...
Backport #25388 by @wolfogre
The old code generates `structs.Repository.Permissions` with only
`access.Permission.AccessMode`, however, it should check the units too,
or the value could be incorrect. For example,
`structs.Repository.Permissions.Push` could be false even the doer has
write access to code unit.
Should fix
https://github.com/renovatebot/renovate/issues/14059#issuecomment-1047961128
(Not reported by it, I just found it when I was looking into this bug)
---
Review tips:
The major changes are
- `modules/structs/repo.go`
https://github.com/go-gitea/gitea/pull/25388/files#diff-870406f6857117f8b03611c43fca0ab9ed6d6e76a2d0069a7c1f17e8fa9092f7
- `services/convert/repository.go`
https://github.com/go-gitea/gitea/pull/25388/files#diff-7736f6d2ae894c9edb7729a80ab89aa183b888a26a811a0c1fdebd18726a7101
And other changes are passive.
Co-authored-by: Jason Song <i@wolfogre.com >
2023-06-22 17:01:42 +02:00
Giteabot and silverwind
056829749e
Diff page enhancements ( #25398 ) ( #25437 )
...
Backport #25398 by @silverwind
Two small tweaks:
1. Vertically center arrow here when editing a PR:
<img width="405" alt="Screenshot 2023-06-20 at 19 48 49"
src="https://github.com/go-gitea/gitea/assets/115237/1d63764d-9fd9-467e-8a8e-9258c06475eb ">
2. Use 2-row layout on diff viewed status and show it again on mobile:
<img width="142" alt="Screenshot 2023-06-20 at 19 51 21"
src="https://github.com/go-gitea/gitea/assets/115237/3046e782-163c-4f87-910c-a22066de8f1b ">
Mobile view:
<img width="370" alt="Screenshot 2023-06-20 at 19 44 40"
src="https://github.com/go-gitea/gitea/assets/115237/9cf56347-7323-4d05-99a5-17ad215ee44d ">
Co-authored-by: silverwind <me@silverwind.io >
2023-06-22 14:33:13 +02:00
Giteabot and Zettat123
f18b8e7d8a
Change default email domain for LDAP users ( #25425 ) ( #25434 )
...
Backport #25425 by @Zettat123
Fixes #21169
Change `localhost` to `localhost.local`
Co-authored-by: Zettat123 <zettat123@gmail.com >
2023-06-22 10:53:15 +00:00
Giteabot and silverwind
ea00ed320d
Various UI fixes ( #25264 ) ( #25431 )
...
Backport #25264 by @silverwind
Numerous small UI fixes:
- Fix double border in collaborator list
- Fix system notice table background
- Mute links in repo and org lists
- Downsize projects edit buttons
- Improve milestones and project list rendering
- Condense milestone list entry to a single line of "metas"
- Mute ".." button in repo files list
<img width="899" alt="Screenshot 2023-06-14 at 21 19 23"
src="https://github.com/go-gitea/gitea/assets/115237/40d70006-5f76-49ad-b43c-4343ec3311e1 ">
<img width="905" alt="Screenshot 2023-06-14 at 21 18 29"
src="https://github.com/go-gitea/gitea/assets/115237/46ef39ea-ab26-452d-89b0-a55d0cfacfdb ">
<img width="270" alt="Screenshot 2023-06-14 at 21 14 09"
src="https://github.com/go-gitea/gitea/assets/115237/aa16e833-a03b-4231-bc7c-159a6a6bee19 ">
<img width="409" alt="Screenshot 2023-06-14 at 21 12 13"
src="https://github.com/go-gitea/gitea/assets/115237/b5242d41-f87a-4837-b0cf-9cc4c1f43daf ">
<img width="286" alt="Screenshot 2023-06-14 at 21 10 03"
src="https://github.com/go-gitea/gitea/assets/115237/d0c36e47-651b-4d34-ad95-3d59474a7c3e ">
<img width="928" alt="Screenshot 2023-06-14 at 21 05 24"
src="https://github.com/go-gitea/gitea/assets/115237/fc3b713e-d252-40f5-b6ba-6e5a741ab500 ">
<img width="217" alt="Screenshot 2023-06-14 at 21 02 01"
src="https://github.com/go-gitea/gitea/assets/115237/c4c33376-18d6-4820-aff5-f508f6d351a0 ">
<img width="79" alt="Screenshot 2023-06-14 at 20 42 43"
src="https://github.com/go-gitea/gitea/assets/115237/034b5950-c0bf-473b-a2f7-0c27a0259f29 ">
<img width="607" alt="Screenshot 2023-06-14 at 21 00 42"
src="https://github.com/go-gitea/gitea/assets/115237/fba2d3fd-bd3e-4daf-8b2f-530a1c99c8bc ">
Co-authored-by: silverwind <me@silverwind.io >
2023-06-22 10:19:38 +00:00
Giteabot and Jason Song
ffe089432f
Fix missing commit message body when the message has leading newlines ( #25418 ) ( #25422 )
...
Backport #25418 by @wolfogre
Commit with `echo "\nmessage after a blank line\nsecond line of the
message" | git commit --cleanup=verbatim -F -` and push.
<img width="1139" alt="image"
src="https://github.com/go-gitea/gitea/assets/9418365/f9a2c28c-e307-4c78-9e31-3d3ace7b9274 ">
Co-authored-by: Jason Song <i@wolfogre.com >
2023-06-21 13:55:08 +02:00
Giteabot and wxiaoguang
8302b95d6b
Avoid polluting config file when "save" ( #25395 ) ( #25406 )
...
Backport #25395 by @wxiaoguang
That's a longstanding INI package problem: the "MustXxx" calls change
the option values, and the following "Save" will save a lot of garbage
options into the user's config file.
Ideally we should refactor the INI package to a clear solution, but it's
a huge work.
A clear workaround is what this PR does: when "Save", load a clear INI
instance and save it.
Partially fix #25377 , the "install" page needs more fine tunes.
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com >
2023-06-21 04:51:26 +00:00
Giteabot and Lunny Xiao
6f1c95ec5b
Use the new download domain replace the old ( #25405 ) ( #25409 )
...
Backport #25405 by @lunny
As title.
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com >
2023-06-21 03:59:51 +00:00
Giteabot and wxiaoguang
cda69a0363
Fix dropdown icon layout on diff page ( #25397 ) ( #25403 )
...
Backport #25397 by @wxiaoguang
Address
https://github.com/go-gitea/gitea/pull/25163#issuecomment-1599207916
Remove the unused "icon-button".
And fix the layout:
Without the dropdown icon:
```
{{svg "gitea-whitespace"}}
```

With the dropdown icon:
```
{{svg "gitea-whitespace" 16 "gt-mr-3"}}
{{svg "octicon-triangle-down" 14 "dropdown icon"}}
```

Co-authored-by: wxiaoguang <wxiaoguang@gmail.com >
2023-06-21 10:55:11 +08:00
Giteabot and Lunny Xiao
4908cc9adf
Fix blank dir message when uploading files from web editor ( #25391 ) ( #25400 )
...
Backport #25391 by @lunny
Fix #7883
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com >
2023-06-20 20:28:52 +00:00
Giteabot and techknowlogick
28ed763f55
Use Actions git context instead of dynamically created buildkit one ( #25381 ) ( #25383 )
...
Backport #25381 by @techknowlogick
The [docker/build-push-action@v2
action](https://github.com/docker/build-push-action ) by default ignores
the checkout created using the actions/checkout@v2 action. When you pass
a git build context to docker build, it wouldn't include the .git
directory.
By passing `context: .` to the build step then it'll use the Actions git
context which includes the git fetch from the earlier step.
Co-authored-by: techknowlogick <techknowlogick@gitea.io >
2023-06-20 08:52:38 +02:00
Giteabot and Zettat123
dfefe86045
Fix LDAP sync when Username Attribute is empty ( #25278 ) ( #25379 )
...
Backport #25278 by @Zettat123
Fix #21072

Username Attribute is not a required item when creating an
authentication source. If Username Attribute is empty, the username
value of LDAP user cannot be read, so all users from LDAP will be marked
as inactive by mistake when synchronizing external users.
This PR improves the sync logic, if username is empty, the email address
will be used to find user.
Co-authored-by: Zettat123 <zettat123@gmail.com >
2023-06-20 13:11:22 +08:00
Giteabot and techknowlogick
10fcb55507
Fetch all git data for embedding correct version in docker image ( #25361 ) ( #25373 )
...
Backport #25361 by @techknowlogick
Fix #25350
Co-authored-by: techknowlogick <techknowlogick@gitea.io >
2023-06-20 03:07:51 +00:00
Giteabot and wxiaoguang
e9105ac281
Fix label list divider ( #25312 ) ( #25372 )
...
Backport #25312 by @wxiaoguang
We only needs 2 lines to hide the dividers.
```
$dropdownLabelFilter.dropdown('setting', {'hideDividers': 'empty'});
$dropdownLabelFilter.dropdown('refreshItems');
```
Other code blocks are refactored by the way.


Co-authored-by: wxiaoguang <wxiaoguang@gmail.com >
2023-06-19 18:14:31 +00:00
Giteabot and Denys Konovalov
e6e1cfd8e4
fix issue filters on mobile view ( #25368 ) ( #25371 )
...
Backport #25368 by @denyskon
Fix #24846 applying the solution proposed by @silverwind
<details>
<summary>Screenshots</summary>






</details>
Replaces #25335
Co-authored-by: Denys Konovalov <kontakt@denyskon.de >
2023-06-19 17:43:22 +00:00
Giteabot and Daniel Wolf
072997692c
Fix incorrect actions ref_name ( #25358 ) ( #25367 )
...
Backport #25358 by @nephatrine
Fix #25357 .
Just a simple fix the result of `${{ gitea.ref_name }}` to show the
shortened name rather than the full ref.
Co-authored-by: Daniel Wolf <1461334+nephatrine@users.noreply.github.com >
2023-06-19 18:37:52 +02:00
Giteabot and wxiaoguang
e9fab3ea3e
Avoid polluting the config ( #25345 ) ( #25354 )
...
Backport #25345 by @wxiaoguang
Caught by #25330
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com >
2023-06-18 20:56:50 +00:00
Giteabot and Philip Miglinci
cc73f6e821
Add Exoscale to installation on cloud provider docs ( #25342 ) ( #25346 )
...
Backport #25342 by @pmig
We created a Gitea application for the [Exoscale
Marketplace](https://www.exoscale.com/marketplace/listing/glasskube-gitea/ )
for easier installation on the European cloud provider.
The installation is managed via the [Glasskube Kubernetes
Operator](https://github.com/glasskube/operator ).
Signed-off-by: Philip Miglinci <pmig@glasskube.eu >
Co-authored-by: Philip Miglinci <p.miglinci@gmail.com >
2023-06-18 15:48:06 +00:00
Giteabot and wxiaoguang
ff18c3ba65
Write absolute AppDataPath to app.ini when installing ( #25331 ) ( #25347 )
...
Backport #25331 by @wxiaoguang
If the APP_DATA_PATH isn't written into the config when installing, then
its value is uncertain because some Gitea command doesn't run with
correct WorkPath.
This is a quick fix for #25330 and can be backported.
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com >
2023-06-18 15:07:46 +00:00
b673edbeaf
Fix UI on mobile view ( #25315 ) ( #25340 )
...
Backport #25315 by @denyskon
Various fixes to pages or elements which were looking ugly on mobile.
<details>
<summary>Screenshots</summary>









</details>
Co-authored by: @silverwind
Co-authored-by: Denys Konovalov <kontakt@denyskon.de >
Co-authored-by: silverwind <me@silverwind.io >
2023-06-18 13:02:41 +00:00
Giteabot and techknowlogick
aa4c9c3215
build nightly docker images ( #25317 ) ( #25333 )
...
Backport #25317 by @techknowlogick
followup of https://github.com/go-gitea/gitea/pull/25308 this time to
build & push nightly docker images
Co-authored-by: techknowlogick <techknowlogick@gitea.io >
2023-06-18 11:09:30 +00:00
Giteabot and hiifong
4e79c76ed0
When viewing a file, hide the add button ( #25320 ) ( #25339 )
...
Backport #25320 by @hiifong
Fix #25281
When viewing a file, hide the add button


Co-authored-by: hiifong <i@hiif.ong >
2023-06-18 10:24:54 +00:00
Giteabot and silverwind
3bd311c3f4
Remove EasyMDE focus outline on text ( #25328 ) ( #25332 )
...
Backport #25328 by @silverwind
EasyMDE in Firefox currently shows a ugly outline in the fake textarea
the CodeMirror uses. Hide it.
Before:
<img width="845" alt="Screenshot 2023-06-18 at 02 54 09"
src="https://github.com/go-gitea/gitea/assets/115237/dc406166-9ad5-4a9b-9581-002b5cdcc6df ">
After:
<img width="870" alt="Screenshot 2023-06-18 at 02 54 24"
src="https://github.com/go-gitea/gitea/assets/115237/ddd78759-2cf2-4385-b863-7576fec25c34 ">
Co-authored-by: silverwind <me@silverwind.io >
2023-06-18 09:35:40 +02:00
Giteabot and silverwind
e5629d9701
Remove more unused Fomantic variants ( #25292 ) ( #25323 )
...
Backport #25292 by @silverwind
Save another 50KB of CSS by removing unused and useless Fomantic
variants.
Removed the last instance of a `tertiary` button and fixed a TODO:
<img width="509" alt="Screenshot 2023-06-15 at 22 34 36"
src="https://github.com/go-gitea/gitea/assets/115237/8a16ae7b-2b17-439b-a096-60a52724e3d6 ">
Co-authored-by: silverwind <me@silverwind.io >
2023-06-17 17:14:25 +02:00
4ea38bba73
Build nightly binaries with Actions ( #25308 ) ( #25314 )
...
Backport #25308 by @techknowlogick
Co-authored-by: techknowlogick <techknowlogick@gitea.io >
Co-authored-by: silverwind <me@silverwind.io >
2023-06-16 19:59:20 +02:00