Backport #35876 by @silverwind
1. Set a fixed height on the element, preventing the content after the
element from shifting on page load. This uses CSS [container query
length
units](https://developer.mozilla.org/en-US/docs/Web/CSS/CSS_containment/Container_queries#container_query_length_units)
as I saw no other way because of the non-linear scaling of the element.
2. Move the "total-contributions" text into the existing vue slot,
eliminating the need for absolute positioning.
Co-authored-by: silverwind <me@silverwind.io>
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
Backport #35861 by @divyun
Since 1.25.0, the dates get set to `2001-01-01T00:00:00Z`, when not
specified by the caller.
Fixes#35860
Co-authored-by: Divyun Raje Vaid <mail@divyun.com>
Backport #35840#35783 fixes an actions rerun bug. Due to this bug, some runs may be
incorrectly marked as `StatusWaiting` even though all the jobs are in
done status. These runs cannot be run or cancelled. This PR adds a new
doctor command to fix the inconsistent run status.
```
gitea doctor check --run fix-actions-unfinished-run-status --fix
```
Fix#35781, #27472
Backport #35819
The PR will not correct the wrong numbers automatically.
There is a cron task `check_repo_stats` which will be run when Gitea
start or midnight. It will correct the numbers.
Backport #35793 by @silverwind
During https://github.com/go-gitea/gitea/issues/35790, it was noticed
that this PNG image had the wrong file extension. I also verified
`dingtalk.ico` and that one is actually an `.ico`.
Co-authored-by: silverwind <me@silverwind.io>
Backport #35783Fix#35780, fix#35782
Rerunning a job or a run is only allowed when the job is done and the
run is done.
Related PR: #3497098ff7d0773/routers/web/repo/actions/view.go (L239)
We don't need to check run status again in `rerunJob` because the run
status has been changed before `rerunJob`.
---
In fact, the bug described in the above issues will not occur on the
main branch. Because `getRunJobs` is called before updating the run.
98ff7d0773/routers/web/repo/actions/view.go (L425-L435)
So the run status that `rerunJob` checks is the old status.
---------
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
Backport #35739 by wxiaoguang
This is a follow up for #35662, and also fix#31181, help #30275, fix
#31161
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
Backport #35679 by surya-purohit
shows the main LFS filesize instead of the pointer filesize when viewing
a file
Co-authored-by: Surya Purohit <suryaprakash.sharma@sourcefuse.com>
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
Backport #35647
This PR moved the creation of pushing comments before pull request
mergeable checking. So that when the pull request status changed, the
comments should have been created.
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
Backport #35604 by silverwind
The test calls out to a web service which may be down or unreachable as
seen in the linked issue. It's better for tests to not have such
external dependencies to make them absolutely stable.
Fixes: https://github.com/go-gitea/gitea/issues/35571
Co-authored-by: silverwind <me@silverwind.io>
Backport #35610 by @surya-purohit
Updates the swagger documentation for the `diffpatch` API endpoint.
The request body is corrected from the outdated `UpdateFileOptions` to
the current `ApplyDiffPatchOptions` to match the code implementation.
Closes [issue#35602](https://github.com/go-gitea/gitea/issues/35602)
---------
Co-authored-by: Surya Purohit <suryaprakash.sharma@sourcefuse.com>
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
Backport #35584 by @shashank-netapp
# Summary
The Gitea codebase was logging `Elasticsearch` and `Meilisearch`
connection strings directly to log files without sanitizing them. Since
connection strings often contain credentials in the format
`protocol://username:password@host:port`, this resulted in passwords
being exposed in plain text in log output.
Fix:
- wrapped all instances of setting.Indexer.RepoConnStr and
setting.Indexer.IssueConnStr with the `util.SanitizeCredentialURLs()`
function before logging them.
Fixes: #35530
Co-authored-by: shashank-netapp <108022276+shashank-netapp@users.noreply.github.com>
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>