aboutsummaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* Fix the PR review form bug during frontend refactor (#17332)wxiaoguang2021-10-161-1/+1
|
* Split `index.js` to separate files (#17315)wxiaoguang2021-10-1742-3502/+3687
| | | | | | | | | | | | | | | | | | * split `index.js` to separate files * tune clipboard * fix promise * fix document * remove intermediate empty file * fix async event listener * use `export function` instead of `export {}`, add more comments Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com> Co-authored-by: 6543 <6543@obermui.de>
* Add RSS/Atom feed support for user actions (#16002)65432021-10-1622-39/+1521
| | | Return rss/atom feed for user based on rss url suffix or Content-Type header.
* Add simple update checker to Gitea (#17212)techknowlogick2021-10-168-3/+195
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Add simple update checker to Gitea * update struct and remove comments * fix lint * Update custom/conf/app.example.ini * Update docs/content/doc/advanced/config-cheat-sheet.en-us.md Co-authored-by: delvh <dev.lh@web.de> * Update custom/conf/app.example.ini Co-authored-by: delvh <dev.lh@web.de> * Update docs/content/doc/advanced/config-cheat-sheet.en-us.md Co-authored-by: delvh <dev.lh@web.de> * Update docs/content/doc/advanced/config-cheat-sheet.en-us.md Co-authored-by: Steven <61625851+justusbunsi@users.noreply.github.com> * Update docs/content/doc/advanced/config-cheat-sheet.en-us.md * Update modules/cron/tasks_extended.go Co-authored-by: wxiaoguang <wxiaoguang@gmail.com> * Update custom/conf/app.example.ini Co-authored-by: wxiaoguang <wxiaoguang@gmail.com> * take PR feedback into account and display banner on admin dashboard for alerts * Add more detailed message * placate lint * update per feedback Co-authored-by: delvh <dev.lh@web.de> Co-authored-by: Steven <61625851+justusbunsi@users.noreply.github.com> Co-authored-by: 6543 <6543@obermui.de> Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
* Update documents for Gitea behind reverse proxy. Fix some small bugs (some ↵wxiaoguang2021-10-155-20/+22
| | | | | | | | | | | URLs are generated without sub-path) (#17320) * Apache `ProxyPassReverse` only works for Location, Content-Location and URI headers on HTTP redirect responses, it causes more problems than it resolves. Now all URLs generated by Gitee have the correct prefix AppSubURL. We do not need to set `ProxyPassReverse`. * fix url param * use AppSubURL instead of AppURL in api/v1 Co-authored-by: techknowlogick <techknowlogick@gitea.io>
* fix: issue close/comment buttons on mobile (#17317)kolaente2021-10-151-29/+39
| | | | | | | | * fix: issue close/comment buttons on mobile * fix: lint Co-authored-by: techknowlogick <techknowlogick@gitea.io> Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
* fix: code review comments on mobile (#17321)kolaente2021-10-163-5/+59
| | | Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
* [skip ci] Updated translations via CrowdinGiteaBot2021-10-162-3/+15
|
* Check for context exceeded in WalkGitLog (#17319)zeripath2021-10-151-0/+3
| | | | | | | | | | | There is a slight race in checking of a context deadline exceed in #16467 which leads to a 500 on the repository page. The solution is to check the error coming back from `*LogNameStatusRepoParser.Next()` and if it is the `ContextDeadlineExceeded` break from the loop. Fix #17314 Signed-off-by: Andrew Thornton <art27@cantab.net>
* Add buttons to allow loading of incomplete diffs (#16829)zeripath2021-10-1512-154/+227
| | | | | | | | | | | | | | | | | This PR adds two buttons to the stats and the end of the diffs list to load the (some of) the remaining incomplete diff sections. Contains #16775 Signed-off-by: Andrew Thornton <art27@cantab.net> ## Screenshots ### Show more button at the end of the diff ![Screenshot from 2021-09-04 11-12-37](https://user-images.githubusercontent.com/1824502/132091009-b1f6113e-2c04-4be5-8a04-b8ecea56887b.png) ### Show more button at the end of the diff stats box ![Screenshot from 2021-09-04 11-14-54](https://user-images.githubusercontent.com/1824502/132091063-86da5a6d-6628-4b82-bea9-3655cd9f40f6.png)
* Multiple tokens support for migrating from github (#17134)Lunny Xiao2021-10-153-84/+134
| | | | | | | | | * multiple tokens support for migrating from github * improve code and token description * Fix bug * Add comment for get client
* Frontend refactor: move Vue related code from `index.js` to `components` ↵wxiaoguang2021-10-1520-634/+718
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | dir, and remove unused codes. (#17301) * frontend refactor * Apply suggestions from code review Co-authored-by: delvh <dev.lh@web.de> * Update templates/base/head.tmpl Co-authored-by: delvh <dev.lh@web.de> * Update docs/content/doc/developers/guidelines-frontend.md Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com> * fix typo * fix typo * refactor PageData to pageData * Apply suggestions from code review Co-authored-by: delvh <dev.lh@web.de> * Simply for the visual difference. Co-authored-by: delvh <dev.lh@web.de> * Revert "Apply suggestions from code review" This reverts commit 4d78ad9b0e96ca180e0823de17659a2e0814c099. Co-authored-by: delvh <dev.lh@web.de> Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com> Co-authored-by: 6543 <6543@obermui.de>
* [skip ci] Updated translations via CrowdinGiteaBot2021-10-151-0/+25
|
* Show direct match on top for user search (#17303)Maximilian Weiler2021-10-151-2/+8
| | | | | | | | | This PR makes sure that direct matches in the user search always show on top of the result list. The following places were checked to follow the desired behavior now: - Search when adding a user to a team - Search when adding a user as a collaborator to a repository Signed-off-by: Maximilian Weiler <16721506+maweil@users.noreply.github.com>
* Don't panic if we fail to parse U2FRegistration data (#17304)David Jimenez2021-10-143-2/+28
| | | | | | | | | * Don't panic if we fail to parse a U2FRegistration data Downgrade logging statement from Fatal to Error so that errors parsing U2FRegistration data does not panic; instead, the invalid key will be skipped and we will attempt to parse the next one, if available. Signed-off-by: David Jimenez <dvejmz@sgfault.com>
* Upgrade chi to v5 (#17298)Lunny Xiao2021-10-1335-132/+2692
|
* [skip ci] Updated translations via CrowdinGiteaBot2021-10-141-0/+25
|
* Ensure that git daemon export ok is created for mirrors (#17243)zeripath2021-10-137-29/+81
| | | | | | | | | | | | | * Ensure that git daemon export ok is created for mirrors There is an issue with #16508 where it appears that create repo requires that the repo does not exist. This causes #17241 where an error is reported because of this. This PR fixes this and also runs update-server-info for mirrors and generated repos. Fix #17241 Signed-off-by: Andrew Thornton <art27@cantab.net>
* Disable core.protectNTFS (#17300)zeripath2021-10-134-0/+10
| | | | | | | | | | | | | | core.protectNTFS protects NTFS from files which may be difficult to remove or interact with using the win32 api, however, it also appears to prevent such files from being entered into the git indexes - fundamentally causing breakages with PRs that affect these files. However, deliberately setting this to false may cause security issues due to the remain sparse checkout of files in the merge pipeline. The only sensible option therefore is to provide an optional setting which admins could set which would forcibly switch this off if they are affected by this issue. Fix #17092 Signed-off-by: Andrew Thornton <art27@cantab.net>
* Use pointer for wrappedConn methods (#17295)zeripath2021-10-121-3/+3
| | | | | Fix #17294 Signed-off-by: Andrew Thornton <art27@cantab.net>
* Add user status filter to admin user management page (#16770)wxiaoguang2021-10-1217-36/+233
| | | | | | | | | | | | | | | | | | | | It makes Admin's life easier to filter users by various status. * introduce window.config.PageData to pass template data to javascript module and small refactor move legacy window.ActivityTopAuthors to window.config.PageData.ActivityTopAuthors make HTML structure more IDE-friendly in footer.tmpl and head.tmpl remove incorrect <style class="list-search-style"></style> in head.tmpl use log.Error instead of log.Critical in admin user search * use LEFT JOIN instead of SubQuery when admin filters users by 2fa. revert non-en locale. * use OptionalBool instead of status map * refactor SearchUserOptions.toConds to SearchUserOptions.toSearchQueryBase * add unit test for user search * only allow admin to use filters to search users
* [API] Add endpount to get user org permissions (#17232)Romain2021-10-127-1/+325
| | | | | | | | | | | | * Add endpoint * Add swagger response + generate swagger * Stop execution if user / org is not found * Add tests Co-authored-by: 6543 <6543@obermui.de>
* [skip ci] Updated translations via CrowdinGiteaBot2021-10-122-0/+19
|
* AutoRegistration is supposed to be working with disabled registration (#17219)Viktor Kuzmin2021-10-111-1/+1
| | | | Co-authored-by: 6543 <6543@obermui.de> Co-authored-by: Lauris BH <lauris@nix.lv>
* Open markdown image links in new window (#17287)wxiaoguang2021-10-112-4/+8
|
* [skip ci] Updated translations via CrowdinGiteaBot2021-10-112-0/+17
|
* Save and view issue/comment content history (#16909)wxiaoguang2021-10-1017-8/+766
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * issue content history * Use timeutil.TimeStampNow() for content history time instead of issue/comment.UpdatedUnix (which are not updated in time) * i18n for frontend * refactor * clean up * fix refactor * re-format * temp refactor * follow db refactor * rename IssueContentHistory to ContentHistory, remove empty model tags * fix html * use avatar refactor to generate avatar url * add unit test, keep at most 20 history revisions. * re-format * syntax nit * Add issue content history table * Update models/migrations/v197.go Co-authored-by: 6543 <6543@obermui.de> * fix merge Co-authored-by: zeripath <art27@cantab.net> Co-authored-by: 6543 <6543@obermui.de> Co-authored-by: Lauris BH <lauris@nix.lv>
* [skip ci] Updated translations via CrowdinGiteaBot2021-10-101-0/+5
|
* [skip ci] Updated translations via CrowdinGiteaBot2021-10-091-0/+12
|
* changelog for 1.15.4 (frontport) (#17273)techknowlogick2021-10-082-1/+24
|
* Add a simple way to rename branch like gh (#15870)a10121127962021-10-0814-1/+357
| | | | | | | | | | - Update default branch if needed - Update protected branch if needed - Update all not merged pull request base branch name - Rename git branch - Record this rename work and auto redirect for old branch on ui Signed-off-by: a1012112796 <1012112796@qq.com> Co-authored-by: delvh <dev.lh@web.de>
* Move add deploy key form before the list and add a cancel button (#17228)qwerty2872021-10-082-34/+42
|
* Defer Last Commit Info (#16467)zeripath2021-10-0813-151/+321
| | | | | | | | | | | One of the biggest reasons for slow repository browsing is that we wait until last commit information has been generated for all files in the repository. This PR proposes deferring this generation to a new POST endpoint that does the look up outside of the main page request. Signed-off-by: Andrew Thornton <art27@cantab.net>
* Remove heads pointing to missing old refs (#17076)99rgosse2021-10-082-0/+22
| | | | | Co-authored-by: zeripath <art27@cantab.net> Co-authored-by: Lauris BH <lauris@nix.lv> Co-authored-by: 6543 <6543@obermui.de>
* Fix incorrect repository count on organization tab of dashboard (#17256)Jimmy Praet2021-10-081-1/+1
| | | Fixes #17249
* Allow adding multiple issues to a project (#17226)qwerty2872021-10-082-0/+32
| | | | Adds an option like for adding multiple issues to a milestone. Closes #17216
* Fix unwanted team review request deletion (#17257)Jimmy Praet2021-10-071-1/+1
| | | | Add missing issue_id = ? to where clause Fixes #17251
* Handle duplicate keys on GPG key ring (#17242)zeripath2021-10-071-0/+40
| | | | | | | | | | It is possible that a keyring can contain duplicate keys on a keyring due to jpegs or other layers. This currently leads to a confusing error for the user - where we report a duplicate key insertion. This PR simply coalesces keys into one key if there are duplicates. Signed-off-by: Andrew Thornton <art27@cantab.net> Co-authored-by: 6543 <6543@obermui.de>
* Fix broken Activities link in team dashboard (#17255)Jimmy Praet2021-10-071-1/+1
| | | | | Remove '/' suffix from organization dashboard link Fixes #17250
* Add protection to disable Gitea when run as root (#17168)techknowlogick2021-10-072-3/+33
| | | | Co-authored-by: delvh <dev.lh@web.de> Co-authored-by: 6543 <6543@obermui.de>
* API pull's head/base have correct permission (#17214)pricly-yellow2021-10-074-22/+34
| | | | | | | | | | close #17181 * for all pull requests API return permissions of caller * for all webhook return empty permissions Signed-off-by: Danila Kryukov <pricly_yellow@dismail.de> Co-authored-by: delvh <dev.lh@web.de> Co-authored-by: 6543 <6543@obermui.de>
* Fix problem when database ID is not incremented as expected (#17229)finga2021-10-063-3/+3
| | | | | | Although #17124 fixed the same issue for the feed, some other parts with the same issue were found. Co-authored-by: finga <finga@onders.org>
* fix navbar ui (#17235)wxiaoguang2021-10-061-1/+1
|
* CI: migrate from 'plugins/s3:1' to 'woodpeckerci/plugin-s3:latest' (#17234)65432021-10-061-3/+3
| | | | - this fixes the CI release upload issues, as the docker image for this is freshly built (unlike the mostly unmaintained "official" drone plugins), thus containing current CA certs needed for letsencrypt since 2021-09-31. - woodpecker is a drone-ci fork maintained partially by @6543. it's API compatible with current drone plugins afaik
* Avatar refactor, move avatar code from `models` to `models.avatars`, remove ↵wxiaoguang2021-10-0615-300/+274
| | | | | | | | | | | | | | | | duplicated code (#17123) Why this refactor The goal is to move most files from `models` package to `models.xxx` package. Many models depend on avatar model, so just move this first. And the existing logic is not clear, there are too many function like `AvatarLink`, `RelAvatarLink`, `SizedRelAvatarLink`, `SizedAvatarLink`, `MakeFinalAvatarURL`, `HashedAvatarLink`, etc. This refactor make everything clear: * user.AvatarLink() * user.AvatarLinkWithSize(size) * avatars.GenerateEmailAvatarFastLink(email, size) * avatars.GenerateEmailAvatarFinalLink(email, size) And many duplicated code are deleted in route handler, the handler and the model share the same avatar logic now.
* Remove Dashboard/Home button from the navbar (#16844)n2021-10-051-8/+4
| | | | | This removes the Dashboard/Home buttons and adds its text to the title of the logo. Co-authored-by: Alexey 〒erentyev <axifnx@gmail.com>
* Redirect on project after issue created (#17211)Romain2021-10-052-1/+9
| | | | | close #17011 If user create an issue with button in project view, after issue is created the user is redirect to project view.
* Add metrics to get issues by repository (#17225)Romain2021-10-055-35/+73
|
* Add specific event type to header (#17222)John Olheiser2021-10-051-3/+8
| | | | | | | * Add specific event type to header Signed-off-by: jolheiser <john.olheiser@gmail.com> * Change single to type
* Fix stange behavior of DownloadPullDiffOrPatch in incorect index (#17223)pricly-yellow2021-10-053-17/+11
| | | | | | | Fix GetPullRequestByIndex by validate index > 1 Signed-off-by: Danila Kryukov <pricly_yellow@dismail.de> Co-authored-by: a1012112796 <1012112796@qq.com>