]>
source.dussan.org Git - gitea.git/log
zeripath [Fri, 7 May 2021 16:28:02 +0000 (17:28 +0100)]
Defer closing the gitrepo until the end of the wrapped context functions (#15653) (#15746)
* Defer closing the gitrepo until the end of the wrapped context functions (#15653)
Backport #15653
There was a mistake in #15372 where deferral of gitrepo close occurs before it should.
This PR fixes this.
zeripath [Fri, 7 May 2021 15:44:35 +0000 (16:44 +0100)]
Drop back to use IsAnInteractiveSession for SVC (#15749) (#15762)
Backport #15749
* Drop back to use IsAnInteractiveSession for SVC
There is an apparent permission change problem when using
IsWindowsService to determine if the SVC manager should be
used.
This PR simply drops back to using IsAnInteractiveSession as
this does not change behaviour.
Fix #15454
Signed-off-by: Andrew Thornton <art27@cantab.net>
* Yes staticcheck I know this is deprecated
Signed-off-by: Andrew Thornton <art27@cantab.net>
* Just leave me alone lint
Signed-off-by: Andrew Thornton <art27@cantab.net>
Co-authored-by: 6543 <6543@obermui.de>
6543 [Fri, 7 May 2021 15:07:39 +0000 (17:07 +0200)]
Fix bug where repositories appear unadopted (#15757) (#15767)
Fix bug where repositories with capital letters in their names appear unadopted.
Fix #15755
Co-authored-by: zeripath <art27@cantab.net>
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
6543 [Fri, 7 May 2021 14:13:20 +0000 (16:13 +0200)]
not show `ref-in-new-issue` pop when issue was disabled (#15761) (#15765)
fix #15718
Signed-off-by: a1012112796 <1012112796@qq.com>
Co-authored-by: a1012112796 <1012112796@qq.com>
6543 [Fri, 7 May 2021 13:06:19 +0000 (15:06 +0200)]
Issue list alignment tweaks (#15483) (#15766)
Co-authored-by: silverwind <me@silverwind.io>
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
Co-authored-by: zeripath <art27@cantab.net>
zeripath [Fri, 7 May 2021 12:04:17 +0000 (13:04 +0100)]
Fix setting version table in dump (#15753) (#15759)
Backport #15753
* Fix setting version table in dump
As noted on Discord there is a problem with gitea dump where the version table
is not being dumped correctly.
This is due to a missing pointer in the TableInfo.
This PR fixes this.
Signed-off-by: Andrew Thornton <art27@cantab.net>
* Update models_test.go
zeripath [Thu, 6 May 2021 22:14:15 +0000 (23:14 +0100)]
Fix close button change on delete in simplemde area (#15737) (#15747)
Backport #15737
* Fix close button change on delete in simplemde area
Fix issue with close button changing when deleting in the simplemde textarea.
Signed-off-by: Andrew Thornton <art27@cantab.net>
* apply suggestion
Co-authored-by: 6543 <6543@obermui.de>
Co-authored-by: 6543 <6543@obermui.de>
a1012112796 [Thu, 6 May 2021 19:23:26 +0000 (03:23 +0800)]
fix some ui bug about draft release (#15137) (#15745)
* fix some ui bug about draft release
- should not show draft release in tag list because
it will't create real tag
- still show draft release without tag and commit message
for draft release instead of 404 error
- remove tag load for attachement links because it's useless
Signed-off-by: a1012112796 <1012112796@qq.com>
* add test code
* fix test
That's because has added a new release in relaese test database.
* fix dropdown link for draft release
Tomás Warynyca [Wed, 5 May 2021 05:10:01 +0000 (02:10 -0300)]
Fix webkit calendar icon color on arc-green (#15728)
6543 [Tue, 4 May 2021 12:03:31 +0000 (14:03 +0200)]
Only log Error on getLastCommitStatus error to let pull list still be visible (#15715)
Kyle D [Tue, 4 May 2021 06:00:29 +0000 (00:00 -0600)]
Move tooltip down to allow selection of Remove File on error (#15672) (#15714)
zeripath [Mon, 3 May 2021 21:30:30 +0000 (22:30 +0100)]
Fix setting redis db path (#15698) (#15708)
Backport #15698
There is a bug setting the redis db in the common nosql manager whereby the db path
always fails.
This PR fixes this.
Signed-off-by: Andrew Thornton <art27@cantab.net>
Kyle D [Mon, 3 May 2021 17:27:00 +0000 (11:27 -0600)]
Implement delete release attachments and update release attachments' name (#14130) (#15666)
* Implement delete release attachment
* Add attachments on release edit page
* Fix bug
* Finish del release attachments
* Fix frontend lint
* Fix tests
* Support edit release attachments
* Added tests
* Remove the unnecessary parameter isCreate from UpdateReleaseOrCreatReleaseFromTag
* Rename UpdateReleaseOrCreatReleaseFromTag to UpdateRelease
* Fix middle align
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
zeripath [Mon, 3 May 2021 14:51:41 +0000 (15:51 +0100)]
Performance improvement for last commit cache and show-ref (#15455) (#15701)
Backport #15455
* Improve performance when there are multiple commits in the last commit cache
* read refs directly if we can
Signed-off-by: Andrew Thornton <art27@cantab.net>
zeripath [Sun, 2 May 2021 09:43:01 +0000 (10:43 +0100)]
Fix DB session cleanup (#15697) (#15700)
Backport #15697
The DB session clean up needs to check expiry not created_unix.
Signed-off-by: Andrew Thornton <art27@cantab.net>
6543 [Sat, 1 May 2021 00:14:36 +0000 (02:14 +0200)]
Fixed several activation bugs (#15473) (#15685)
* Removed unneeded form tag.
* Fixed typo.
* Fixed NPE.
* Use better error page.
* Splitted GET and POST.
Co-authored-by: KN4CK3R <KN4CK3R@users.noreply.github.com>
6543 [Fri, 30 Apr 2021 22:09:58 +0000 (00:09 +0200)]
Delete references if repository gets deleted (#15681) (#15684)
* Remove DeletedBranch and LFSLocks.
* Sort beans.
Co-authored-by: KN4CK3R <KN4CK3R@users.noreply.github.com>
Co-authored-by: zeripath <art27@cantab.net>
6543 [Fri, 30 Apr 2021 21:27:26 +0000 (23:27 +0200)]
Fix orphaned objects deletion bug (#15657) (#15683)
* Fix orphaned objects deletion bug
* extend test
Co-authored-by: 6543 <6543@obermui.de>
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
Co-authored-by: zeripath <art27@cantab.net>
KN4CK3R [Fri, 30 Apr 2021 18:59:42 +0000 (20:59 +0200)]
Delete protected branch if repository gets removed (#15658) (#15676)
* Added missing error parameters.
* Delete protected branch if repository gets removed.
* Added doctor fix.
6543 [Wed, 28 Apr 2021 19:24:56 +0000 (21:24 +0200)]
[API] pull notification subject status: add "merged" (#15344) (#15654)
Current subject status can be "", "open" and "closed". This add "merged" to it.
zeripath [Wed, 28 Apr 2021 17:50:56 +0000 (18:50 +0100)]
Remove spurious set name from eventsource.sharedworker.js (#15643) (#15652)
Backport #15643
Fix #15617
Signed-off-by: Andrew Thornton <art27@cantab.net>
zeripath [Wed, 28 Apr 2021 00:20:47 +0000 (01:20 +0100)]
not update updated uinx for `git gc` (#15637) (#15641)
Backport #15637
fix #15634
Signed-off-by: a1012112796 <1012112796@qq.com>
Co-authored-by: a1012112796 <1012112796@qq.com>
zeripath [Mon, 26 Apr 2021 19:25:51 +0000 (20:25 +0100)]
Fix commit graph author link (#15627) (#15630)
Backport #15627
The author link on the commit graph is incorrect and isn't providing a link to the author.
Signed-off-by: Andrew Thornton <art27@cantab.net>
Lunny Xiao [Mon, 26 Apr 2021 12:42:12 +0000 (20:42 +0800)]
fix webhook timeout bug (#15613) (#15621)
* Also fix the potential problem in httplib
techknowlogick [Sun, 25 Apr 2021 15:58:42 +0000 (11:58 -0400)]
Resolve panic on failed interface conversion in migration v156 (#15604) (#15610)
go panics otherwise with `panic: interface conversion: error is git.ErrNotExist, not *git.ErrNotExist`, thanks to Codeberg/Andi for reporting this.
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
Nathan Smith [Sun, 25 Apr 2021 06:01:52 +0000 (23:01 -0700)]
Bump unrolled/render to v1.1.0 (#15581) (#15608)
v1.1.0 has improved buffer pooling
Lunny Xiao [Fri, 23 Apr 2021 12:56:21 +0000 (20:56 +0800)]
Fix missing storage init (#15589) (#15598)
zeripath [Thu, 22 Apr 2021 20:30:18 +0000 (21:30 +0100)]
If the default branch is not present do not report error on stats indexing (follow-up of #15546) (#15583) (#15594)
Backport #15546
Backport #15583
#15546 doesn't completely fix this problem because the error returned is an ObjectNotExist
error not a BranchNotExist error.
Add test for ErrObjectNotExist too
Fix #15257
Signed-off-by: Andrew Thornton <art27@cantab.net>
Lunny Xiao [Thu, 22 Apr 2021 18:32:48 +0000 (02:32 +0800)]
Fix lfs management find (#15537) (#15578)
* Fix lfs management find (#15537)
Fix #15236
* Do not do 40byte conversion within ParseTreeLine
* Missed a to40ByteSHA
Signed-off-by: Andrew Thornton <art27@cantab.net>
Co-authored-by: Andrew Thornton <art27@cantab.net>
* Remove space
Co-authored-by: Andrew Thornton <art27@cantab.net>
zeripath [Wed, 21 Apr 2021 21:59:50 +0000 (22:59 +0100)]
Add placeholder text to deploy key textarea (#15575) (#15576)
Backport #15575
Add placeholder text to deploy key textarea
Related #15574
Signed-off-by: Andrew Thornton <art27@cantab.net>
zeripath [Wed, 21 Apr 2021 19:11:43 +0000 (20:11 +0100)]
Fix NPE on view commit with notes (#15561) (#15573)
Backport #15561
Fix #15558
Signed-off-by: Andrew Thornton <art27@cantab.net>
silverwind [Tue, 20 Apr 2021 19:45:00 +0000 (21:45 +0200)]
Project board improvements (#15429) (#15560)
* Project board improvements
- Fix link colors
- Extract CSS to own file
- Various minor tweaks to make it look better
Fixes: https://github.com/go-gitea/gitea/issues/15424
Fixes: https://github.com/go-gitea/gitea/issues/15506
Fixes: https://github.com/go-gitea/gitea/pull/15511
* fix squashed cards on small view area
* more css fixes, add second row from issue list
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
Co-authored-by: 6543 <6543@obermui.de>
Co-authored-by: techknowlogick <techknowlogick@gitea.io>
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
Co-authored-by: 6543 <6543@obermui.de>
Co-authored-by: techknowlogick <techknowlogick@gitea.io>
KN4CK3R [Tue, 20 Apr 2021 16:01:58 +0000 (18:01 +0200)]
Add ETag header (#15370) (#15552)
* Add ETag header.
* Comply with RFC 7232.
* Moved logic into httpcache.go
* Changed name.
* Lint
* Implemented If-None-Match list.
* Fixed missing header on *
* Removed weak etag support.
* Removed * support.
* Added unit test.
* Lint
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
Co-authored-by: techknowlogick <techknowlogick@gitea.io>
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
Co-authored-by: techknowlogick <techknowlogick@gitea.io>
Lunny Xiao [Sat, 17 Apr 2021 12:46:30 +0000 (20:46 +0800)]
Fix bug on commit graph (#15517) (#15530)
zeripath [Sat, 17 Apr 2021 11:30:58 +0000 (12:30 +0100)]
Send size to /avatars if requested (#15459) (#15528)
Backport #15459
If an avatar is requested in a particular size ensure that /avatars also gets the size request
Fix #15453
Signed-off-by: Andrew Thornton <art27@cantab.net>
Co-authored-by: 6543 <6543@obermui.de>
zeripath [Sat, 17 Apr 2021 10:13:15 +0000 (11:13 +0100)]
Prevent migration 156 failure if tag commit missing (#15519) (#15527)
Backport #15519
It is possible that tag commits could be deleted or missing from repos. This causes
migration 156 to fail and breaks upgrade.
This PR simply logs the failure.
Signed-off-by: Andrew Thornton <art27@cantab.net>
Mike L [Fri, 16 Apr 2021 05:53:51 +0000 (07:53 +0200)]
Repo branch page: label size, PR ref, new PR button alignment (#15363) (#15365)
6543 [Fri, 16 Apr 2021 02:19:09 +0000 (04:19 +0200)]
Changelog v1.14.1 (#15498)
* RAW Changelog v1.14.1
* wordings
* Apply suggestions from code review
Co-authored-by: techknowlogick <matti@mdranta.net>
* Update CHANGELOG.md
Co-authored-by: 6543 <6543@obermui.de>
* Update CHANGELOG.md
Co-authored-by: 6543 <6543@obermui.de>
Co-authored-by: techknowlogick <matti@mdranta.net>
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
Co-authored-by: techknowlogick <techknowlogick@gitea.io>
6543 [Thu, 15 Apr 2021 22:14:14 +0000 (00:14 +0200)]
Performance improvement for list pull requests (#15447) (#15500)
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
zeripath [Thu, 15 Apr 2021 19:40:10 +0000 (20:40 +0100)]
Fix bug clone wiki (#15499) (#15502)
Backport #15499
Fix #15494
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
Co-authored-by: Lauris BH <lauris@nix.lv>
zeripath [Thu, 15 Apr 2021 15:41:47 +0000 (16:41 +0100)]
dump: Add option to skip LFS/attachment files (#15407) (#15492)
Backport #15407
* Add option to skip dumping LFS/attachment files
* Fix fmt issues
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
Co-authored-by: Johan Van de Wauw <johan@gisky.be>
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
Co-authored-by: Lauris BH <lauris@nix.lv>
zeripath [Thu, 15 Apr 2021 15:24:59 +0000 (16:24 +0100)]
Ensure review dismissal only dismisses the correct review (#15477) (#15489)
Backport #15477
Fix #15472
Signed-off-by: Andrew Thornton art27@cantab.net
Co-authored-by: 6543 <6543@obermui.de>
zeripath [Thu, 15 Apr 2021 15:24:30 +0000 (16:24 +0100)]
Use subdir for URL (#15446) (#15493)
Backport #15446
Fixes #15444
Co-authored-by: KN4CK3R <KN4CK3R@users.noreply.github.com>
Co-authored-by: KN4CK3R <KN4CK3R@users.noreply.github.com>
6543 [Thu, 15 Apr 2021 15:24:01 +0000 (17:24 +0200)]
migration: github: if rate limit is not enabled, ignore it (#15490) (#15495)
Co-authored-by: Lauris BH <lauris@nix.lv>
zeripath [Thu, 15 Apr 2021 14:47:43 +0000 (15:47 +0100)]
Use index of the supported tags to choose user lang (#15452) (#15488)
Backport #15452
Fix #14793.
The previous implementation used the first return value of matcher.Match, which is the chosen language tag but may contain extensions such as de-DE-u-rg-chzzzz.
As mentioned in the documentation of language package, matcher.Match also returns the index of the supported tags, so I think it is better to use it rather than manipulate the returned language tag.
Co-authored-by: Naohisa Murakami <tiqwab.ch90@gmail.com>
Lunny Xiao [Thu, 15 Apr 2021 14:13:14 +0000 (22:13 +0800)]
Fix potential copy lfs records failure when fork a repository (#15441) (#15485)
zeripath [Thu, 15 Apr 2021 13:29:13 +0000 (14:29 +0100)]
Query the DB for the hash before inserting in to email_hash (#15457) (#15491)
Backport #15457
Some postgres users have logging which logs even failed transactions. So
just query the db before trying to insert.
Fix #15451
Signed-off-by: Andrew Thornton art27@cantab.net
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
zeripath [Thu, 15 Apr 2021 12:21:27 +0000 (13:21 +0100)]
Build go-git variants for windows (#15482) (#15487)
Backport #15482
It appears that there are significant performance problems with the pure git backend
on windows.
Therefore until we can sort this out - provide go-git backend builds.
Signed-off-by: Andrew Thornton <art27@cantab.net>
silverwind [Thu, 15 Apr 2021 11:02:57 +0000 (13:02 +0200)]
Lock down build-images dependencies (#15480)
Partial extraction from #15479 for 1.14. Locks down build-images
dependencies and adds missing node_modules dependency.
zeripath [Thu, 15 Apr 2021 10:02:42 +0000 (11:02 +0100)]
Prevent superfluous response.WriteHeader (#15456) (#15476)
Backport #15456
This PR simply checks the status before writing the header.
Signed-off-by: Andrew Thornton <art27@cantab.net>
a1012112796 [Thu, 15 Apr 2021 09:04:25 +0000 (17:04 +0800)]
fix wrong file link in code search page (#15466) (#15486)
in previous the grenrated link is
``testg/testrepo/src/commit/....``
which is not right.
the right version is ``/testg/testrepo/.......``
(start wiht ``/``)
or ``http://127.0.0.1:3000/xxxxx`` (full link)
to make it hase same result with explore page
I choose the secound style.
fix #15438
Signed-off-by: a1012112796 <1012112796@qq.com>
Co-authored-by: 6543 <6543@obermui.de>
Co-authored-by: 6543 <6543@obermui.de>
silverwind [Wed, 14 Apr 2021 21:16:33 +0000 (23:16 +0200)]
Clone panel fixes (#15436)
- Use <button> over <div> for a button
- Fix absent border-right on wiki
- Fix absent border-radius on wiki
John Olheiser [Wed, 14 Apr 2021 19:42:30 +0000 (14:42 -0500)]
quick fix (#15464) (#15481)
Signed-off-by: jolheiser <john.olheiser@gmail.com>
zeripath [Wed, 14 Apr 2021 18:53:01 +0000 (19:53 +0100)]
Fix ambiguous argument error on tags (#15432) (#15474)
Backport #15432
There is a weird gotcha with GetTagCommitID that because it uses git rev-list
can cause an ambiguous argument error.
This PR simply makes tags use the same code as branches.
Signed-off-by: Andrew Thornton <art27@cantab.net>
techknowlogick [Wed, 14 Apr 2021 06:03:42 +0000 (02:03 -0400)]
v172 migration adds created_unix field instead of expiry (#15458) (#15463)
The Session table must have an Expiry field not a created_unix field - somehow
this migration adds the incorrect named field leading to #15445 reports.
Fix #15445
Signed-off-by: Andrew Thornton <art27@cantab.net>
Co-authored-by: zeripath <art27@cantab.net>
techknowlogick [Tue, 13 Apr 2021 04:30:28 +0000 (00:30 -0400)]
Fix repository search (#15428) (#15442)
Co-authored-by: zeripath <art27@cantab.net>
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
Co-authored-by: KN4CK3R <KN4CK3R@users.noreply.github.com>
Co-authored-by: zeripath <art27@cantab.net>
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
techknowlogick [Tue, 13 Apr 2021 02:50:07 +0000 (22:50 -0400)]
Prevent NPE on avatar direct rendering if federated avatars disabled (#15434) (#15439)
#13649 assumed that direct avatar urls would always be libravatar urls - this leads
to NPEs if federated avatar service is disabled.
Fix #15421
Signed-off-by: Andrew Thornton <art27@cantab.net>
Co-authored-by: techknowlogick <techknowlogick@gitea.io>
Co-authored-by: zeripath <art27@cantab.net>
silverwind [Mon, 12 Apr 2021 21:59:56 +0000 (23:59 +0200)]
Fix wiki clone urls (#15430) (#15431)
Fix wiki clone urls
Regressed by: https://github.com/go-gitea/gitea/commit/
9a4050f1e839af1bd072aff9ac5fc69e650747c8
Fixes: https://github.com/go-gitea/gitea/issues/15420
Tomás Warynyca [Mon, 12 Apr 2021 15:10:49 +0000 (12:10 -0300)]
fix dingtalk icon url (#15426)
Co-authored-by: techknowlogick <techknowlogick@gitea.io>
zeripath [Mon, 12 Apr 2021 08:05:20 +0000 (09:05 +0100)]
Standardise icon on projects PR page (#15387) (#15408)
Backport #15387
Fix #15272
Signed-off-by: Andrew Thornton <art27@cantab.net>
6543 [Sun, 11 Apr 2021 17:48:35 +0000 (19:48 +0200)]
use repo1_bare to test against (#15402) (#15404)
Mike L [Sun, 11 Apr 2021 15:50:03 +0000 (17:50 +0200)]
Use semantic dropdown for code search query type (#15276) (#15364)
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
Co-authored-by: 6543 <6543@obermui.de>
6543 [Sun, 11 Apr 2021 04:07:02 +0000 (06:07 +0200)]
Changelog v1.14.0 (#15360)
* clean & merge & update v1.14.0 changelog
* backport v1.13.x changelogs
Lunny Xiao [Sun, 11 Apr 2021 02:57:44 +0000 (10:57 +0800)]
Fix delete nonexist oauth application 500 and prevent deadlock (#15384) (#15396)
* Fix delete nonexist oauth application 500
* Fix test
* Close the session
* Fix more missed sess.Close
* Remove unnecessary blank line
Signed-off-by: Andrew Thornton <art27@cantab.net>
Co-authored-by: Andrew Thornton <art27@cantab.net>
Co-authored-by: 6543 <6543@obermui.de>
zeripath [Sat, 10 Apr 2021 12:08:30 +0000 (13:08 +0100)]
Always set the merge base used to merge the commit (#15352) (#15385)
Backport #15352
The issue is that the TestPatch will reset the PR MergeBase - and it is possible for TestPatch to update the MergeBase whilst a merge is ongoing. The ensuing merge will then complete but it doesn't re-set the MergeBase it used to merge the PR.
Fixes the intermittent error in git test.
Signed-off-by: Andrew Thornton art27@cantab.net
zeripath [Sat, 10 Apr 2021 02:24:40 +0000 (03:24 +0100)]
Turn RepoRef and RepoAssignment back into func(*Context) (#15372) (#15377)
Backport #15372
Signed-off-by: Andrew Thornton <art27@cantab.net>
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
silverwind [Fri, 9 Apr 2021 23:43:36 +0000 (01:43 +0200)]
Dropzone styling improvements (#15291) (#15374)
* Dropzone styling improvements
- Move all dropzone styles to separate file
- Fix white background in arc-green
- Fix rendering of non-square images and previews
* increase thumbnail quality, set contain in js, replace blur effect with opacity
Co-authored-by: techknowlogick <techknowlogick@gitea.io>
zeripath [Fri, 9 Apr 2021 23:41:30 +0000 (00:41 +0100)]
Upgrade to bluemonday 1.0.7 (#15379) (#15380)
* Upgrade to bluemonday 1.0.7 (#15379)
Backport #15379
Fix #15349
Signed-off-by: Andrew Thornton <art27@cantab.net>
* resolve CI
Co-authored-by: techknowlogick <techknowlogick@gitea.io>
zeripath [Fri, 9 Apr 2021 16:45:02 +0000 (17:45 +0100)]
Move FCGI req.URL.Path fix-up to the FCGI listener (#15292) (#15361)
Backport #15292
Simplify the web.go FCGI path by moving the req.URL.Path fix-up to listener
Signed-off-by: Andrew Thornton <art27@cantab.net>
6543 [Fri, 9 Apr 2021 10:39:40 +0000 (12:39 +0200)]
Fix `admin user list` (#15358) (#15359)
* Fix `admin user list` (#15358)
* fix routers/api/v1/repo/issue.go
silverwind [Fri, 9 Apr 2021 03:38:06 +0000 (05:38 +0200)]
Fix button border issue (#15351)
silverwind [Fri, 9 Apr 2021 01:54:24 +0000 (03:54 +0200)]
Disable cssnano's colormin plugin (#15348)
It produces odd rgba values which also seem to cause issues in monaco's
color parser where the scoll shadow went red for some reason.
Regression by: https://github.com/go-gitea/gitea/pull/15333
zeripath [Thu, 8 Apr 2021 19:36:17 +0000 (20:36 +0100)]
Show diff on rename with diff changes (#15338) (#15339)
Backport #15338
More recent versions of git have increased support for detection of renames meaning
that a rename with diff changes is now supported.
Although ParsePatch supports this - our templates do not and the simplest solution
is simply to show the diff.
Fix #15335
Signed-off-by: Andrew Thornton <art27@cantab.net>
Co-authored-by: 6543 <6543@obermui.de>
zeripath [Thu, 8 Apr 2021 16:51:10 +0000 (17:51 +0100)]
Prepend AppSubUrl to links for default avatar (#15341) (#15342)
Backport #15341
Fix #15334
Signed-off-by: Andrew Thornton <art27@cantab.net>
zeripath [Thu, 8 Apr 2021 15:28:30 +0000 (16:28 +0100)]
Fix handling of logout event (#15323) (#15337)
Backport #15323
It appears that there is a slight bug in the handling of the data of logout event -
the javascript should be testing the data field of the data field for the logout
instruction.
Signed-off-by: Andrew Thornton <art27@cantab.net>
silverwind [Thu, 8 Apr 2021 11:24:23 +0000 (13:24 +0200)]
Monaco improvements (#15333) (#15345)
- Create theme at runtime which follows the CSS variables of the site
- Disable a few opinionated Monaco defaults like minimap and word highlights
- Move styles to separate file
6543 [Wed, 7 Apr 2021 20:14:11 +0000 (22:14 +0200)]
Fix CanCreateRepo check (#15311) (#15321)
Signed-off-by: jolheiser <john.olheiser@gmail.com>
Co-authored-by: John Olheiser <john.olheiser@gmail.com>
6543 [Wed, 7 Apr 2021 07:36:15 +0000 (09:36 +0200)]
Fix xorm log stack level (#15285) (#15316)
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
6543 [Wed, 7 Apr 2021 03:07:39 +0000 (05:07 +0200)]
Reduce memory usage in testgit (#15306) (#15310)
* reduce memory use in rawtest
* just use hashsum for diffs
Signed-off-by: Andrew Thornton <art27@cantab.net>
Co-authored-by: zeripath <art27@cantab.net>
Co-authored-by: techknowlogick <techknowlogick@gitea.io>
KN4CK3R [Tue, 6 Apr 2021 19:25:31 +0000 (21:25 +0200)]
Close file on invalid range (Addition to #15166) (#15268) (#15308)
* Close file on invalid range.
* Close on seek error
Signed-off-by: Andrew Thornton <art27@cantab.net>
* Moved 'Seek' into server.
* io.ReadSeekCloser is only available in Go 1.16
Co-authored-by: Andrew Thornton <art27@cantab.net>
Co-authored-by: Lauris BH <lauris@nix.lv>
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
Co-authored-by: Andrew Thornton <art27@cantab.net>
Co-authored-by: Lauris BH <lauris@nix.lv>
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
Co-authored-by: techknowlogick <techknowlogick@gitea.io>
6543 [Tue, 6 Apr 2021 16:44:24 +0000 (18:44 +0200)]
Fix bug in Wrap (#15302) (#15309)
Whilst doing other work I have noticed that there is an issue with Wrap when passing an
http.Handler - the next should be the next handler in line not empty.
Signed-off-by: Andrew Thornton <art27@cantab.net>
Co-authored-by: zeripath <art27@cantab.net>
6543 [Tue, 6 Apr 2021 00:36:58 +0000 (02:36 +0200)]
Update to bluemonday-1.0.6 (#15294) (#15297)
Signed-off-by: Andrew Thornton <art27@cantab.net>
Co-authored-by: zeripath <art27@cantab.net>
zeripath [Mon, 5 Apr 2021 00:39:22 +0000 (01:39 +0100)]
Drop the event source if we are unauthorized (#15275) (#15280)
Backport #15275
A previous commit that sent unauthorized if the user is unauthorized
simply leads to the repeated reopening of the eventsource. #
This PR changes the event returned to tell the client to close the
eventsource and thus prevents the repeated reopening.
Signed-off-by: Andrew Thornton <art27@cantab.net>
zeripath [Sun, 4 Apr 2021 16:04:55 +0000 (17:04 +0100)]
Add size to Save function (#15264) (#15270)
This PR proposes an alternative solution to #15255 - just add the size to the
save function. Yes it is less apparently clean but it may be more correct.
Close #15255
Fix #15253
Signed-off-by: Andrew Thornton <art27@cantab.net>
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
silverwind [Sun, 4 Apr 2021 13:31:54 +0000 (15:31 +0200)]
Branch page and misc css improvements (#15208) (#15274)
- Improve branches page, increase icon size, use octicons, use css vars
- Style placeholder color via css var
- Slightly increase contrast of input fields and active/hover states
- Add styling for select boxes in arc-green
techknowlogick [Sat, 3 Apr 2021 08:42:18 +0000 (04:42 -0400)]
update golang libraries (#15258) (#15259)
KN4CK3R [Fri, 2 Apr 2021 03:29:14 +0000 (05:29 +0200)]
Fix graph pagination (#15225) (#15249)
* Fixed invalid HTML tag.
* Fixed pagination.
* Update templates/repo/graph/commits.tmpl
Co-authored-by: zeripath <art27@cantab.net>
a1012112796 [Thu, 1 Apr 2021 23:57:05 +0000 (07:57 +0800)]
response 404 for diff/patch of a commit that not exist (#15221) (#15237)
* response 404 for diff/patch of a commit that not exist
fix #15217
Signed-off-by: a1012112796 <1012112796@qq.com>
* Update routers/repo/commit.go
Co-authored-by: silverwind <me@silverwind.io>
* use ctx.NotFound()
Co-authored-by: zeripath <art27@cantab.net>
Co-authored-by: silverwind <me@silverwind.io>
Co-authored-by: zeripath <art27@cantab.net>
Co-authored-by: silverwind <me@silverwind.io>
Co-authored-by: 6543 <6543@obermui.de>
zeripath [Thu, 1 Apr 2021 23:16:00 +0000 (00:16 +0100)]
Speed up `enry.IsVendor` (#15213) (#15245)
Backport #15213
`enry.IsVendor` is kinda slow as it simply iterates across all regexps.
This PR ajdusts the regexps to combine them to make this process a
little quicker.
Related #15143
Signed-off-by: Andrew Thornton <art27@cantab.net>
zeripath [Thu, 1 Apr 2021 19:14:56 +0000 (20:14 +0100)]
Prevent NPE in CommentMustAsDiff if no hunk header (#15199) (#15200)
Backport #15199
I do not understand how this can happen or why.
There is an apparent possibility for a comment.Patch to be missing a hunk header
- this should not happen and do not understand how. But it appears to happen on
1.13 at least in some case.
This PR will simply add a new section if the cursection is empty
thus preventing the NPE.
Fix #15198
Signed-off-by: Andrew Thornton <art27@cantab.net>
Co-authored-by: 6543 <6543@obermui.de>
mayswind [Thu, 1 Apr 2021 10:22:54 +0000 (18:22 +0800)]
Fix timezone bug when clicking heatmap (#15141) (#15231)
silverwind [Thu, 1 Apr 2021 05:04:47 +0000 (07:04 +0200)]
Diff box fixes (#15214) (#15227)
- Fix misaligned "Show Outdated" buttons via flexbox
- Add hover effect to "Show Outdated" buttons
- Remove overreaching margin from selector .diff-file-box and handle
cases individually.
Fixes: https://github.com/go-gitea/gitea/issues/15097
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
Co-authored-by: 6543 <6543@obermui.de>
Co-authored-by: zeripath <art27@cantab.net>
Co-authored-by: techknowlogick <techknowlogick@gitea.io>
zeripath [Wed, 31 Mar 2021 23:15:08 +0000 (00:15 +0100)]
Improve /api/v1/repos/issues/search by just getting repo ids (#15179) (#15192)
Backport #15179
/api/v1/repos/issues/search is a highly inefficient search which is unfortunately
the basis for our dependency searching algorithm. In particular it currently loads
all of the repositories and their owners and their primary coding language all of
which is immediately thrown away.
This PR makes one simple change - just get the IDs.
Related #14560
Related #12827
Signed-off-by: Andrew Thornton <art27@cantab.net>
zeripath [Wed, 31 Mar 2021 19:49:46 +0000 (20:49 +0100)]
Fix regression from #14623 - use debug SVC handler only on interactive sessions (#15210) (#15211)
Backport #15210
Unfortunately #14623 changed from the deprecated IsInteractiveSession to
IsWindowsService without recognising that they are the complement of
each other.
This means that Windows SVC control is not working correctly. This PR
adds some Tracing statements but also fixes the bug.
Fix #15159
Signed-off-by: Andrew Thornton <art27@cantab.net>
a1012112796 [Wed, 31 Mar 2021 02:56:19 +0000 (10:56 +0800)]
add 'fonts' into 'KnownPublicEntries' (#15188) (#15218)
fix #15184
Signed-off-by: a1012112796 <1012112796@qq.com>
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
silverwind [Tue, 30 Mar 2021 11:15:12 +0000 (13:15 +0200)]
Fix webhook delivery and issue checklist for arc-green (#15195) (#15204)
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
silverwind [Mon, 29 Mar 2021 21:36:00 +0000 (23:36 +0200)]
Fix margin between avatars on org pages (#15194) (#15197)
Fixes: https://github.com/go-gitea/gitea/issues/15191
a1012112796 [Mon, 29 Mar 2021 16:02:01 +0000 (00:02 +0800)]
should run RetrieveRepoMetas() for empty pr (#15187) (#15190)
Signed-off-by: a1012112796 <1012112796@qq.com>
Norwin [Sat, 27 Mar 2021 14:57:02 +0000 (14:57 +0000)]
fix org navbar (#15174)
Co-authored-by: Jimmy Praet <jimmy.praet@telenet.be>
zeripath [Sat, 27 Mar 2021 02:48:38 +0000 (02:48 +0000)]
Clusterfuzz found another way (#15160) (#15168)
Backport #15160
Clusterfuzz found another way so I found another way to stop it
Signed-off-by: Andrew Thornton <art27@cantab.net>