summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* refactor httplib (#18338)Gusted2022-01-191-285/+7
| | | | | | - Remove a lot of unused code(most if not all were introduced in gogs for webhooks usages). Co-authored-by: techknowlogick <techknowlogick@gitea.io>
* Propagate context and ensure git commands run in request context (#17868)zeripath2022-01-19193-1152/+1262
| | | | | | | | | This PR continues the work in #17125 by progressively ensuring that git commands run within the request context. This now means that the if there is a git repo already open in the context it will be used instead of reopening it. Signed-off-by: Andrew Thornton <art27@cantab.net>
* Upgrade Alpine from 3.13 to 3.15 (#18050)v1.17.0-devGrzegorz Alibożek2022-01-194-10/+18
| | | | | | | | | | | * Upgrade alpine to 3.15 * Add executability test to entrypoint for too old dockers Signed-off-by: Andrew Thornton <art27@cantab.net> * Update docker/rootless/usr/local/bin/docker-entrypoint.sh Co-authored-by: zeripath <art27@cantab.net>
* [skip ci] Updated translations via CrowdinGiteaBot2022-01-191-56/+20
|
* Stop trimming preceding and suffixing spaces from editor filenames (#18334)v1.16.0-rc1zeripath2022-01-193-2/+3
| | | | | | | | | | | | | | * Stop trimming preceding and suffixing spaces from editor filenames In #5702 it was decided to trim preceding and suffixed spaces aswell as / from editing file filenames. This was because at this point in time the url-safety of Gitea was much poorer. We can now drop this requirement and file editing should work correctly. Fix #18176 Signed-off-by: Andrew Thornton <art27@cantab.net>
* [skip ci] Updated translations via CrowdinGiteaBot2022-01-192-10/+7
|
* Left-Align text in Unicode warning boxes (#18331)silverwind2022-01-191-2/+2
| | | | | | Wrapped text is more readable when left-aligned. Co-authored-by: Lauris BH <lauris@nix.lv> Co-authored-by: zeripath <art27@cantab.net>
* Only warn on bidi but still escape non-bidi (#18333)zeripath2022-01-191-1/+1
| | | | | Fix #18324 Signed-off-by: Andrew Thornton <art27@cantab.net>
* Fix incorrect OAuth message (#18332)wxiaoguang2022-01-192-3/+3
| | | | | As the title, Fix #18327
* [skip ci] Updated translations via CrowdinGiteaBot2022-01-1910-49/+3661
|
* Changelog for 1.16.0-rc1 (#18309)techknowlogick2022-01-191-0/+294
| | | | | Co-authored-by: Andrew Thornton <art27@cantab.net> Co-authored-by: Lauris BH <lauris@nix.lv> Co-authored-by: 6543 <6543@obermui.de>
* Restore propagation of ErrDependenciesLeft (#18325)zeripath2022-01-193-6/+9
| | | | | | | | | | | Unfortunately #17643 prevented all propagation of ErrDependenciesLeft meaning that dependency errors that prevent closing of issues get swallowed. This PR restores propagation of the error but instead swallows the error in the places where it needs to be swallowed. Fix #18223 Signed-off-by: Andrew Thornton <art27@cantab.net>
* Fix PR comments UI (#18323)wxiaoguang2022-01-197-27/+64
| | | | | Closes: * Review comment cannot be edited #17768 * Changing PR Comment Resolved State Disables Further Changes #18315
* Make the height of the editor in Review Box smaller (4 lines as GitHub) (#18319)wxiaoguang2022-01-193-11/+20
| | | And shrink the height of Dropzone.
* Fix commit links on compare page (#18310)Gusted2022-01-181-5/+6
| | | | | | | | | * Fix commit links on compare page - Use the correct repo link for each commit(the headrepo). As for compare pages were baserepo != headrepo, it wouldn't have the correct link. Co-authored-by: zeripath <art27@cantab.net>
* Update JS dependencies, remove eslint-plugin-github (#18317)silverwind2022-01-184-2910/+1660
| | | | | | | | - Update all JS dependencies - Add new lint rules - Regenerate SVGs - Tested Monaco and Mermaid * Remove eslint-plugin-github
* Add MirrorUpdated field to Repository API type (#18267)Peter Gardfjäll2022-01-183-1/+13
| | | | | Add the last update time to the repository api type. Close #18266
* replace satori/go.uuid with gofrs/uuid (#18311)zeripath2022-01-182-5/+10
| | | Signed-off-by: Andrew Thornton <art27@cantab.net>
* Place inline diff comment dialogs in the 4th column. (#18321)JonRB2022-01-181-1/+1
| | | | | | | | | | | | Comment dialogs for inline comments should appear in 4th column (not 3rd column), this PR changes the column that the inline review comment is associated with. This problem has occurred due to an unrecognised conflict between #17562 and #17315. Fix as zeripath suggested in #18320 Fix #18320 Co-authored-by: zeripath <art27@cantab.net>
* Use indirect comparison when showing pull requests (#18313)zeripath2022-01-183-7/+7
| | | | | | | | When generating the commits list and number of files changed for PRs and compare we should use "..." always not "..". Fix #18303 Signed-off-by: Andrew Thornton <art27@cantab.net>
* Prevent ambiguous column error in organizations page (#18314)zeripath2022-01-181-5/+5
| | | | | | | | Explicitly set the table for the org_id column queries on the organizations pages. Fix #18229 Signed-off-by: Andrew Thornton <art27@cantab.net>
* Correctly upload LFS files (#18316)zeripath2022-01-182-0/+2
| | | | | | | | We need to use the cached .gitattributes file for checking if a file should be stored in the lfs. Fix #18297 Signed-off-by: Andrew Thornton <art27@cantab.net>
* [skip ci] Updated translations via CrowdinGiteaBot2022-01-182-1/+21
|
* update description about vendoring in CONTRIBUTING.md (#18280)a10121127962022-01-172-9/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | * update description about vendoring in CONTRIBUTING.md follow #18277 Signed-off-by: a1012112796 <1012112796@qq.com> * Update CONTRIBUTING.md Co-authored-by: wxiaoguang <wxiaoguang@gmail.com> * fix and readd test-vendor step * remove vendor from .gitattributes @silverwind * simplify go mod check Signed-off-by: a1012112796 <1012112796@qq.com> * Revert "remove vendor from .gitattributes @silverwind" This reverts commit 4789e704cb7a2c80934e4a4cd31efb161e6c8666. Co-authored-by: wxiaoguang <wxiaoguang@gmail.com> Co-authored-by: zeripath <art27@cantab.net> Co-authored-by: 6543 <6543@obermui.de>
* Fix CheckRepoStats and reuse it during migration (#18264)Aravinth Manivannan2022-01-1710-168/+219
| | | | | | | | | | | | | | | | | | | The CheckRepoStats function missed the following counters: - label num_closed_issues & num_closed_pulls - milestone num_closed_issues & num_closed_pulls The update SQL statements for updating the repository num_closed_issues & num_closed_pulls fields were repeated in three functions (repo.CheckRepoStats, migrate.insertIssues and models.Issue.updateClosedNum) and were moved to a single helper. The UpdateRepoStats is implemented and called in the Finish migration method so that it happens immediately instead of wating for the CheckRepoStats to run. Signed-off-by: Loïc Dachary loic@dachary.org --- [source](https://lab.forgefriends.org/forgefriends/forgefriends/-/merge_requests/34)
* Minor tweak to tag list (#18295)silverwind2022-01-171-1/+5
| | | Slightly reduce the font size and padding in the tags table, it seemed a bit too big to me.
* show pull link for agit pull request also (#18235)a10121127962022-01-171-0/+38
|
* [skip ci] Updated translations via CrowdinGiteaBot2022-01-171-0/+22
|
* Add some .ignore entries (#18296)silverwind2022-01-161-2/+5
| | | | Exclude node_modules and minified files from search tools like `rg` and `ag`.
* Remove unneeded debug messages to stdout. (#18298)Ben Niemann2022-01-161-4/+0
| | | Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
* Handle missing default branch better in owner/repo/branches page (#18290)zeripath2022-01-162-54/+65
| | | | | | | This PR more nicely handles a missing default branch in owner/repo/branches Fix #18265 Signed-off-by: Andrew Thornton <art27@cantab.net>
* Revert "Prevent possible XSS when using jQuery (#18289)" (#18293)wxiaoguang2022-01-1610-39/+34
| | | This reverts commit 661d3d28e97bb49bef075c0314edad5879148aaa.
* not show double error response in git hook (#18292)a10121127962022-01-161-1/+1
| | | | | | | | | if return a error message to cli, it will print it to stderr which is duplicate with our code (line 82 in same file). so user will see two line same error message in git output. I think it's not mecessary, so suggerst not return error message to cli. Thanks. Signed-off-by: a1012112796 <1012112796@qq.com>
* Remove accidental debugging in blob_excerpt.tmpl (#18287)zeripath2022-01-161-2/+2
| | | | | | | | | | | * Remove accidental debugging in blob_excerpt.tmpl Unfortunately it appears that a small bit of debugging code was left in blob_excerpt.tmpl This breaks diff expansion causing #18281. Fix #18281 Signed-off-by: Andrew Thornton <art27@cantab.net> Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
* Prevent possible XSS when using jQuery (#18289)Gusted2022-01-1610-34/+39
| | | | | | | In the case of misuse or misunderstanding from a developer whereby, if `sel` can receive user-controlled data, jQuery `$(sel)` can lead to the creation of a new element. Current usage is using hard-coded selectors in the templates, but nobody prevents that from expanding to user-controlled somehow.
* Return nicer error if trying to pull from non-existent user (#18288)zeripath2022-01-161-3/+12
| | | | | | | | | | | * Return nicer error if trying to pull from non-existent user Gitea serv will currently return an 500 if we try to pull from a repository where the owner does not exist. This PR checks for the UserNotExist Error when checking for the user and will return a NotFound error instead. Fix #18225
* [skip ci] Updated translations via CrowdinGiteaBot2022-01-1626-469/+0
|
* docs: mention client_max_body_size affects LFS (#18291)Jan Tojnar2022-01-151-0/+1
|
* Add lockfile-check (#18285)silverwind2022-01-153-1/+14
| | | | | | | * Add lockfile-check This check runs `npm install` which will rewrite the lockfile in case it is inconsistent with package.json. This check detects this and will fail the CI in such a case.
* Webauthn nits (#18284)zeripath2022-01-1510-40/+87
| | | | | | | This contains some additional fixes and small nits related to #17957 Signed-off-by: Andrew Thornton <art27@cantab.net> Co-authored-by: 6543 <6543@obermui.de> Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
* Update `package-lock.json` (#18283)Gusted2022-01-151-35/+35
| | | | | - NPM didn't like that package-lock.json was out-of-sync, webpack throwed some errors as well with building. - Follow-up for: #18278
* Upgrade EasyMDE to 2.16.1 (#18278)wxiaoguang2022-01-151-1/+1
|
* Remove golang vendored directory (#18277)techknowlogick2022-01-146586-2584499/+46
| | | | | | | * rm go vendor * fix drone yaml * add to gitignore
* Changelog for 1.15.10 (#18274) (#18276)zeripath2022-01-142-1/+13
| | | | | | | | | | | | | | | | | | | | | * Changelog for 1.15.10 (#18274) [1.15.10](https://github.com/go-gitea/gitea/releases/tag/v1.15.10) - 2022-01-14 * BUGFIXES * Fix inconsistent PR comment counts (#18260) (#18261) * Fix release link broken (#18252) (#18253) * Fix update user from site administration page bug (#18250) (#18251) * Set HeadCommit when creating tags (#18116) (#18173) * Use correct translation key for error messages due to max repo limits (#18135 & #18153) (#18152) * Fix purple color in suggested label colors (#18241) (#18242) * SECURITY * Bump mermaid from 8.10.1 to 8.13.8 (#18198) (#18206) * update docs/config.yaml Signed-off-by: Andrew Thornton <art27@cantab.net> Co-authored-by: Richard Mahn <richmahn@users.noreply.github.com>
* Support webauthn (#17957)Lunny Xiao2022-01-14224-1075/+35036
| | | | | | | Migrate from U2F to Webauthn Co-authored-by: Andrew Thornton <art27@cantab.net> Co-authored-by: 6543 <6543@obermui.de> Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
* [skip ci] Updated translations via CrowdinGiteaBot2022-01-142-1/+3
|
* Improve the comment for 2FA filter in admin panel (#18017)Gusted2022-01-131-1/+3
| | | | | Replace TODO with explanation Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
* fix regression from #16075 (#18260)Norwin2022-01-141-3/+2
| | | | | | we don't want reviews to count towards comments, as this needs changes in other components as well (eg repo stats cron job, etc). Co-authored-by: 6543 <6543@obermui.de>
* Prevent underline hover on cards (#18259)silverwind2022-01-131-0/+1
| | | | | Prevent a undesired underline effect on hovered cards. This was regressed by #17898.
* Fix release link broken (#18252)Lunny Xiao2022-01-131-1/+1
| | | Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>