summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* Pack web_src/js/draw.js to public/js/index.js (#8975)Lunny Xiao2019-11-148-27/+20
| | | | | | * pack web_src/js/draw.js to public/js/index.js * fix eslint
* Update dashboard context for PR reviews (#8995)John Olheiser2019-11-155-26/+50
| | | | | | | | | | | | | | | | | | * Update dashboard context for PR reviews Signed-off-by: jolheiser <john.olheiser@gmail.com> * Update options/locale/locale_en-US.ini Co-Authored-By: guillep2k <18600385+guillep2k@users.noreply.github.com> * Only append head action if it has content or is approval/rejection Signed-off-by: jolheiser <john.olheiser@gmail.com> * Update options/locale/locale_en-US.ini Co-Authored-By: guillep2k <18600385+guillep2k@users.noreply.github.com>
* Enforce Gitea environment for pushes (#8982)zeripath2019-11-144-18/+42
| | | | | | | | * Enforce Gitea environment for pushes * Update custom/conf/app.ini.sample Co-Authored-By: Antoine GIRARD <sapk@users.noreply.github.com>
* modernize js and use babel (#8973)silverwind2019-11-1410-3740/+5226
| | | | | | | | | | | | | | * modernize js and use babel - add babel toolchain to transform modern JS to ES5 - extend eslint config for modern rules - fixes linting issues via `eslint --fix` and manual fixes * run 'make css' to satisfy CI * code style tweaks and set js indendation to 2 in .editorconfig * regenerate js
* New review approvals shouldn't require a message (#8991)John Olheiser2019-11-141-2/+2
| | | | | | | | | | * New approvals don't require content Signed-off-by: jolheiser <john.olheiser@gmail.com> * Fix edge-bug Signed-off-by: jolheiser <john.olheiser@gmail.com>
* Shadow password correctly for session config (#8984)zeripath2019-11-141-9/+17
| | | | | | | Fix #8718 This PR shadows passwords in session config correctly by detecting the VirtualProvider, unmarshalling the original config and then shadowing config within that.
* Drop Admin attribute based on LDAP when login (continue #1743) (#8849)65432019-11-141-0/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Update User information in Gitea based on LDAP when login * Update Admin Flag only if exist in settings * Fix affectation * Update models/login_source.go Co-Authored-By: JustKiddingCode <JustKiddingCode@users.noreply.github.com> * Better ident * Apply suggestions from code review Update user information Co-Authored-By: 6543 <24977596+6543@users.noreply.github.com> * Make fmt * add err handling * if user exist but login is Prohibit return return nil, and Prohibit err * keep login speed * User sync is implemented at #1478 - so only make sure that admin acces is drpoed if changed * handle error and still use async task * no async * only update admin if Sync is enabled * update two comments * add lafriks suggestions Co-Authored-By: Lauris BH <lauris@nix.lv> * if adminFilter is set - use it Co-Authored-By: Lauris BH <lauris@nix.lv> * Update models/login_source.go well - I should look more detaild at suggestions :D Co-Authored-By: Lauris BH <lauris@nix.lv> * make it work again * set is_admin value to user * look nicer
* fix bug when pack js (#8992)Lunny Xiao2019-11-144-6/+6
|
* Add ALLOW_ONLY_EXTERNAL_REGISTRATION to config cheat sheet (#8986)zeripath2019-11-141-0/+1
| | | | | ALLOW_ONLY_EXTERNAL_REGISTRATION was missed off the cheat sheet. This PR adds it. Fix #8180
* Changelog for 1.10.0 (#8978) (#8987)John Olheiser2019-11-141-22/+34
| | | | | | | | | | * Changelog for 1.10.0 (#8978) Signed-off-by: jolheiser <john.olheiser@gmail.com> * Update security Signed-off-by: jolheiser <john.olheiser@gmail.com>
* [Feature] Add Gitea Emoji (#8950)65432019-11-147-8/+5
| | | | | | | | | | | | | | * add gitea emoji * alphabetic order * Update emojify.js to 1.1.0 * mv to custom * add gitea emoji * minify
* [skip ci] Updated translations via CrowdinGiteaBot2019-11-141-0/+39
|
* fix(docs): Fixed creating Windows service commands (#8979)Wars2019-11-144-4/+4
| | | escaping " to \"
* docs reference latest stable version (1.10.0)techknowlogick2019-11-141-1/+1
|
* Refactor pull request review (#8954)Lunny Xiao2019-11-148-249/+289
| | | | | | | | | | | | | | | | | | * refactor submit review * remove unnecessary code * remove unused comment * fix lint * remove duplicated actions * remove duplicated actions * fix typo * fix comment content
* Backport the backport of 1.9.6 (#8970)John Olheiser2019-11-141-0/+8
| | | Signed-off-by: jolheiser <john.olheiser@gmail.com>
* Fix intermittent GPG Git test failure (#8968)zeripath2019-11-132-126/+209
|
* Add CDNJS to script-src CSP (#8966)John Olheiser2019-11-131-1/+1
|
* Don't send notification on pending reviews (#8943)guillep2k2019-11-131-1/+3
|
* Implement documentation search (#8937)John Olheiser2019-11-1313-4/+362
| | | | | | * Implement documentation search Signed-off-by: jolheiser <john.olheiser@gmail.com> Co-Authored-By: guillep2k <18600385+guillep2k@users.noreply.github.com>
* Move index.js to web_src and use webpack to pack them (#8598)Lunny Xiao2019-11-1312-3793/+4747
| | | | | | | | | | | | * Move index.js to web_src and use webpack * Fix initHeatMap * update eslint and move webpack to devDependencies * update index.js * add eslint env node
* [skip ci] Updated translations via CrowdinGiteaBot2019-11-131-0/+2
|
* add /etc/timezone and /etc/localtime volumes (#8911)Florian Hübner2019-11-131-0/+12
| | | | Passing these volumes to the container enable gitea to use hosts localtime and timezone. This is a mandatory change when using the "Setup fail2ban" Guide, but it is not described in the documentation.
* [skip ci] Updated translations via CrowdinGiteaBot2019-11-131-0/+12
|
* Add Close() method to gogitRepository (#8901)zeripath2019-11-1375-102/+387
| | | | | | | | | In investigating #7947 it has become clear that the storage component of go-git repositories needs closing. This PR adds this Close function and adds the Close functions as necessary. In TransferOwnership the ctx.Repo.GitRepo is closed if it is open to help prevent the risk of multiple open files. Fixes #7947
* Convert EOL to UNIX-style to render MD properly (#8925)guillep2k2019-11-134-1/+120
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Convert EOL to UNIX-style to render MD properly * Update modules/markup/markdown/markdown.go Co-Authored-By: zeripath <art27@cantab.net> * Fix lint optimization * Check for empty content before conversion * Update modules/util/util.go Co-Authored-By: zeripath <art27@cantab.net> * Improved checks and tests * Add paragraph render test * Improve speed even more, improve tests * Small improvement by @gary-kim * Fix test for DOS * More improvements * Restart CI
* Show repository size in repo home page and settings (#8940)Antoine GIRARD2019-11-133-0/+8
| | | | | | * feat: display repository size on repo home and settings * refactor: move repo size up in setting page
* Fix Notify Create Ref Error on tag creation (#8936)zeripath2019-11-131-2/+2
| | | | | | * Fix Notify Create Ref Error on tag creation * Just use the provided full ref instead of BranchCommit
* [skip ci] Updated translations via CrowdinGiteaBot2019-11-1216-16/+1
|
* Update Github Migration Tests (#8938)mrsdizzie2019-11-121-278/+143
| | | | | | | Update all Github migration tests to use a new repo created just for these tests that won't accidentially be modified by regular users interacting with issues. Fixes #8895
* Fix spelling as suggested by @rmbleeker (#8934)guillep2k2019-11-121-1/+1
|
* Move less from public/ to web_src/ so that it will not be packe… (#8908)Lunny Xiao2019-11-1219-3/+3
|
* [skip ci] Updated translations via CrowdinGiteaBot2019-11-123-0/+44
|
* Improve notification (#8835)Lunny Xiao2019-11-127-36/+299
| | | | | | | | | | | | | | | | | | | | * Improve notifications * batch load user * Update notification only when read * Fix reorder * fix lint * fix test * fix lint * make function meaningful * fix comment
* [skip ci] Updated translations via CrowdinGiteaBot2019-11-1130-0/+30
|
* js: Revert change to click behaviour in forceSelection (#8921)Jookia2019-11-111-1/+1
| | | | Calling .click() in forceSelection() in blur() causes a focus loop, this needs a proper fix later but for now just revert the change.
* [skip ci] Updated translations via CrowdinGiteaBot2019-11-111-0/+12
|
* Template Repositories (#8768)John Olheiser2019-11-1158-118/+1440
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Start work on templates Signed-off-by: jolheiser <john.olheiser@gmail.com> * Continue work Signed-off-by: jolheiser <john.olheiser@gmail.com> * Fix IsTemplate vs IsGenerated Signed-off-by: jolheiser <john.olheiser@gmail.com> * Fix tabs vs spaces * Tabs vs Spaces * Add templates to API & start adding tests Signed-off-by: jolheiser <john.olheiser@gmail.com> * Fix integration tests Signed-off-by: jolheiser <john.olheiser@gmail.com> * Remove unused User Signed-off-by: jolheiser <john.olheiser@gmail.com> * Move template tests to existing repos Signed-off-by: jolheiser <john.olheiser@gmail.com> * Minor re-check updates and cleanup Signed-off-by: jolheiser <john.olheiser@gmail.com> * make fmt Signed-off-by: jolheiser <john.olheiser@gmail.com> * Test cleanup Signed-off-by: jolheiser <john.olheiser@gmail.com> * Fix optionalbool Signed-off-by: jolheiser <john.olheiser@gmail.com> * make fmt Signed-off-by: jolheiser <john.olheiser@gmail.com> * Test fixes and icon change Signed-off-by: jolheiser <john.olheiser@gmail.com> * Add new user and repo for tests Signed-off-by: jolheiser <john.olheiser@gmail.com> * Fix tests (finally) Signed-off-by: jolheiser <john.olheiser@gmail.com> * Update meta repo with env variables Signed-off-by: jolheiser <john.olheiser@gmail.com> * Move generation to create page Combine with repo create template Modify API search to prioritize owner for repo Signed-off-by: jolheiser <john.olheiser@gmail.com> * Fix tests and coverage Signed-off-by: jolheiser <john.olheiser@gmail.com> * Fix swagger and JS lint Signed-off-by: jolheiser <john.olheiser@gmail.com> * Fix API searching for own private repos Signed-off-by: jolheiser <john.olheiser@gmail.com> * Change wording Signed-off-by: jolheiser <john.olheiser@gmail.com> * Fix repo search test. User had a private repo that didn't show up Signed-off-by: jolheiser <john.olheiser@gmail.com> * Another search test fix Signed-off-by: jolheiser <john.olheiser@gmail.com> * Clarify git content Co-Authored-By: guillep2k <18600385+guillep2k@users.noreply.github.com> * Feedback updates Signed-off-by: jolheiser <john.olheiser@gmail.com> * Add topics WIP Signed-off-by: jolheiser <john.olheiser@gmail.com> * Finish adding topics Signed-off-by: jolheiser <john.olheiser@gmail.com> * Update locale Signed-off-by: jolheiser <john.olheiser@gmail.com>
* Migrate temp_repo.go to use git.NewCommand (#8918)zeripath2019-11-112-163/+93
| | | | | | | This PR migrates temp_repo.go to use git.NewCommand instead creating processes by itself - this fixes the problem underlying PR #8905. There are other places that run git outside of the controlled locale defined in #8548 but temp_repo.go is the only cause of failure of local testing in cases where English is not the default - implying that error messages from those other commands are not interpreted. Replaces #8905
* Only view branch or tag if it match refType requested. (#8899)David Svantesson2019-11-111-2/+18
| | | | | | * only view branch or tag if it match refName. * remove pointer in method
* Move notifywatchers from models to notification (#8907)Lunny Xiao2019-11-112-10/+26
|
* Fix typo in doc (#8914)Florian Hübner2019-11-101-1/+1
| | | Fix typo in doc fail2ban-setup.md
* Stop using git count-objects and use raw directory size for repository (#8848)zeripath2019-11-104-8/+26
| | | | | * Migrate from git count-objects to a raw directory size * As per @guillep2k ignore unusual files
* Rephrase comment about RuntimeDirectory option (#8912)Anthony Vanelverdinghe2019-11-101-2/+2
|
* Auto-subscribe user to repository when they commit/tag to it (#7657)guillep2k2019-11-1014-29/+296
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Add support for AUTO_WATCH_ON_CHANGES and AUTO_WATCH_ON_CLONE * Update models/repo_watch.go Co-Authored-By: Lauris BH <lauris@nix.lv> * Round up changes suggested by lafriks * Added changes suggested from automated tests * Updated deleteUser to take RepoWatchModeDont into account, corrected inverted DefaultWatchOnClone and DefaultWatchOnChanges behaviour, updated and added tests. * Reinsert import "github.com/Unknwon/com" on http.go * Add migration for new column `watch`.`mode` * Remove serv code * Remove WATCH_ON_CLONE; use hooks, add integrations * Renamed watch_test.go to repo_watch_test.go * Correct fmt * Add missing EOL * Correct name of test function * Reword cheat and ini descriptions * Add update to migration to ensure column value * Clarify comment Co-Authored-By: zeripath <art27@cantab.net> * Simplify if condition
* Adjust error reporting from merge failures and use LC_ALL=C for git (#8548)zeripath2019-11-107-92/+480
| | | | | | There are two major components to this PR: * This PR handles merge and rebase failures from merging a little more nicely with Flash errors rather a 500. * All git commands are run in the LC_ALL="C" environment to ensure that error messages are in English. This DefaultLocale is defined in a way that if necessary (due to platform weirdness) it can be overridden at build time using LDFLAGS="-X "code.gitea.io/gitea/modules/git.DefaultLocale=C"" with C changed for the locale as necessary.
* Fix API Bug (fail on empty assignees) (#8873)65432019-11-103-14/+45
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * keep sure if assigneeIDs == nil -> do nothing * fix #8872 * Revert "keep sure if assigneeIDs == nil -> do nothing" -> go handle it itself preaty well This reverts commit e72d94129c4666d5151f6131cb2f8c1de127d9d0. * clarity comparson Co-Authored-By: guillep2k <18600385+guillep2k@users.noreply.github.com> * simplify * Update models/issue_assignees.go Co-Authored-By: guillep2k <18600385+guillep2k@users.noreply.github.com> * Update issue_assignees.go * simplify more * add --if oneAssignee != ""-- again * Update models/issue_assignees.go Co-Authored-By: guillep2k <18600385+guillep2k@users.noreply.github.com> * CI.restart() * Update issue_assignees.go * add Test for GetUserIDsByNames * add Test for MakeIDsFromAPIAssigneesToAdd * fix test
* Move code.gitea.io/gitea/routers/api/v1/convert to ↵Lunny Xiao2019-11-1026-24/+24
| | | | | | | | code.gitea.io/gitea/modules/convert (#8892) * Move code.gitea.io/gitea/routers/api/v1/convert to code.gitea.io/gitea/modules/convert * fix fmt
* Fix issue with user.fullname (#8902)zeripath2019-11-091-3/+5
|
* Enable punctuations ending mentions (#8889)guillep2k2019-11-092-12/+37
| | | | | | * Enable punctuations ending mentions * Improve tests