- 30 Mar, 2022 4 commits
-
-
Justin Sievenpiper authored
Gitea was not able to supply any authentication parameters to it. So this brings support to do that, along with some light extraction of a couple of bits into some separate functions for easier testing. I looked at other libraries supporting similar RedisUri-style connection strings (e.g. Lettuce), but it looks like this type of configuration is beyond what would typically be done in a connection string. Since gitea doesn't have configuration options for manually specifying all this redis connection detail, I went ahead and just chose straightforward names for these new parameters.
-
KN4CK3R authored
* Added package store settings. * Added models. * Added generic package registry. * Added tests. * Added NuGet package registry. * Moved service index to api file. * Added NPM package registry. * Added Maven package registry. * Added PyPI package registry. * Summary is deprecated. * Changed npm name. * Sanitize project url. * Allow only scoped packages. * Added user interface. * Changed method name. * Added missing migration file. * Set page info. * Added documentation. * Added documentation links. * Fixed wrong error message. * Lint template files. * Fixed merge errors. * Fixed unit test storage path. * Switch to json module. * Added suggestions. * Added package webhook. * Add package api. * Fixed swagger file. * Fixed enum and comments. * Fixed NuGet pagination. * Print test names. * Added api tests. * Fixed access level. * Fix User unmarshal. * Added RubyGems package registry. * Fix lint. * Implemented io.Writer. * Added support for sha256/sha512 checksum files. * Improved maven-metadata.xml support. * Added support for symbol package uploads. * Added tests. * Added overview docs. * Added npm dependencies and keywords. * Added no-packages information. * Display file size. * Display asset count. * Fixed filter alignment. * Added package icons. * Formatted instructions. * Allow anonymous package downloads. * Fixed comments. * Fixed postgres test. * Moved file. * Moved models to models/packages. * Use correct error response format per client. * Use simpler search form. * Fixed IsProd. * Restructured data model. * Prevent empty filename. * Fix swagger. * Implemented user/org registry. * Implemented UI. * Use GetUserByIDCtx. * Use table for dependencies. * make svg * Added support for unscoped npm packages. * Add support for npm dist tags. * Added tests for npm tags. * Unlink packages if repository gets deleted. * Prevent user/org delete if a packages exist. * Use package unlink in repository service. * Added support for composer packages. * Restructured package docs. * Added missing tests. * Fixed generic content page. * Fixed docs. * Fixed swagger. * Added missing type. * Fixed ambiguous column. * Organize content store by sha256 hash. * Added admin package management. * Added support for sorting. * Add support for multiple identical versions/files. * Added missing repository unlink. * Added file properties. * make fmt * lint * Added Conan package registry. * Updated docs. * Unify package names. * Added swagger enum. * Use longer TEXT column type. * Removed version composite key. * Merged package and container registry. * Removed index. * Use dedicated package router. * Moved files to new location. * Updated docs. * Fixed JOIN order. * Fixed GROUP BY statement. * Fixed GROUP BY #2. * Added symbol server support. * Added more tests. * Set NOT NULL. * Added setting to disable package registries. * Moved auth into service. * refactor * Use ctx everywhere. * Added package cleanup task. * Changed packages path. * Added container registry. * Refactoring * Updated comparison. * Fix swagger. * Fixed table order. * Use token auth for npm routes. * Enabled ReverseProxy auth. * Added packages link for orgs. * Fixed anonymous org access. * Enable copy button for setup instructions. * Merge error * Added suggestions. * Fixed merge. * Handle "generic". * Added link for TODO. * Added suggestions. * Changed temporary buffer filename. * Added suggestions. * Apply suggestions from code review Co-authored-by:
Thomas Boerger <thomas@webhippie.de> * Update docs/content/doc/packages/nuget.en-us.md Co-authored-by:
wxiaoguang <wxiaoguang@gmail.com> Co-authored-by:
Thomas Boerger <thomas@webhippie.de>
-
wxiaoguang authored
* ROOT_URL issues: some users did wrong to there app.ini config, then: * The assets can not be loaded (AppSubUrl != "" and users try to access http://host:3000/) *The ROOT_URL is wrong, then many URLs in Gitea are broken. Now Gitea show enough information to users. * JavaScript error issues, there are many users affected by JavaScript errors, some are caused by frontend bugs, some are caused by broken customized templates. If these JS errors can be found at first time, then maintainers do not need to ask about how bug occurs again and again. * Some people like to modify the `head.tmpl`, so we separate the script part to `head_script.tmpl`, then it's much safer. * use specialized CSS class "js-global-error", end users still have a chance to hide error messages by customized CSS styles.
-
GiteaBot authored
-
- 29 Mar, 2022 12 commits
-
-
6543 authored
* OpenRepositoryCtx -> OpenRepository * OpenRepository -> openRepositoryWithDefaultContext, only for internal usage
-
zeripath authored
Strangely #19038 appears to relate to an issue whereby a tag appears to be listed in `git show-ref --tags` but then does not appear when `git show-ref --tags -- short_name` is called. As a solution though I propose to stop the second call as it is unnecessary and only likely to cause problems. I've also noticed that the tags calls are wildly inefficient and aren't using the common cat-files - so these have been added. I've also noticed that the git commit-graph is not being written on mirroring - so I've also added writing this to the migration which should improve mirror rendering somewhat. Fix #19038 Signed-off-by:
Andrew Thornton <art27@cantab.net> Co-authored-by:
6543 <6543@obermui.de>
-
zeripath authored
There is yet another problem with conflicted files not being reset when the test patch resolves them. This PR adjusts the code for checkConflicts to reset the ConflictedFiles field immediately at the top. It also adds a reset to conflictedFiles for the manuallyMerged and a shortcut for the empty status in protectedfiles. Signed-off-by:
Andrew Thornton <art27@cantab.net>
-
John Olheiser authored
Signed-off-by:
jolheiser <john.olheiser@gmail.com> Co-authored-by:
Lunny Xiao <xiaolunwen@gmail.com>
-
Lunny Xiao authored
* Move some issue methods as functions * Fix bug
-
Lunny Xiao authored
* Move project files into models/project sub package * Fix test * Fix test * Fix test * Fix build * Fix test * Fix template bug * Fix bug * Fix lint * Fix test * Fix import * Improve codes Co-authored-by:
6543 <6543@obermui.de>
-
John Olheiser authored
Signed-off-by:
jolheiser <john.olheiser@gmail.com>
-
zeripath authored
* Provide configuration to allow camo-media proxying Fix #916 Signed-off-by:
Andrew Thornton <art27@cantab.net> Co-authored-by:
6543 <6543@obermui.de> Co-authored-by:
wxiaoguang <wxiaoguang@gmail.com>
-
Lunny Xiao authored
* Move init repository related functions to modules * Fix lint * Use ctx but db.DefaultContext Co-authored-by:
wxiaoguang <wxiaoguang@gmail.com>
-
Lunny Xiao authored
* Move organization related structs into sub package * Fix test * Fix lint * Move more functions into sub packages * Fix bug * Fix test * Update models/organization/team_repo.go Co-authored-by:
KN4CK3R <admin@oldschoolhack.me> * Apply suggestions from code review Co-authored-by:
KN4CK3R <admin@oldschoolhack.me> * Fix fmt * Follow suggestion from @Gusted * Fix test * Fix test * Fix bug * Use ctx but db.DefaultContext on routers * Fix bug * Fix bug * fix bug * Update models/organization/team_user.go * Fix bug Co-authored-by:
KN4CK3R <admin@oldschoolhack.me> Co-authored-by:
wxiaoguang <wxiaoguang@gmail.com>
-
wxiaoguang authored
The last PR about clone buttons introduced an JS error when visiting an empty repo page: * https://github.com/go-gitea/gitea/pull/19028 * `Uncaught ReferenceError: isSSH is not defined`, because the variables are scoped and doesn't share between sub templates. This: 1. Simplify `templates/repo/clone_buttons.tmpl` and make code clear 2. Move most JS code into `initRepoCloneLink` 3. Remove unused `CloneLink.Git` 4. Remove `ctx.Data["DisableSSH"] / ctx.Data["ExposeAnonSSH"] / ctx.Data["DisableHTTP"]`, and only set them when is is needed (eg: deploy keys / ssh keys) 5. Introduce `Data["CloneButton*"]` to provide data for clone buttons and links 6. Introduce `Data["RepoCloneLink"]` for the repo clone link (not the wiki) 7. Remove most `ctx.Data["PageIsWiki"]` because it has been set in the `/wiki` middleware 8. Remove incorrect `quickstart` class in `migrating.tmpl`
-
zeripath authored
As discussed on #19221 we should store the results of the last task message on the crontask and show them on the monitor page. Signed-off-by:
Andrew Thornton <art27@cantab.net> Co-authored-by:
wxiaoguang <wxiaoguang@gmail.com>
-
- 28 Mar, 2022 6 commits
-
-
zeripath authored
This PR adds the necessary work to make it possible to create files on empty repos using the API. Fix #10993 Signed-off-by:
Andrew Thornton <art27@cantab.net>
-
Lunny Xiao authored
-
Pilou authored
Add a new cron task which deletes the old system notices.
-
Lunny Xiao authored
* remove the global methods but create dynamiclly * Fix lint * Fix windows lint * Fix windows lint * some improvements Co-authored-by:
wxiaoguang <wxiaoguang@gmail.com>
-
zeripath authored
There is a bug in the system webhooks whereby the active state is not checked when webhooks are prepared and there is a bug that deactivating webhooks do not prevent queued deliveries. * Only add SystemWebhooks to the prepareWebhooks list if they are active * At the time of delivery if the underlying webhook is not active mark it as "delivered" but with a failed delivery so it does not get delivered. Fix #19220 Signed-off-by:
Andrew Thornton <art27@cantab.net> Co-authored-by:
Lunny Xiao <xiaolunwen@gmail.com>
-
GiteaBot authored
-
- 27 Mar, 2022 8 commits
-
-
zeripath authored
So whilst #19225 fixes one issue it caused another. We need to initialise the Git module first. Related #19225 Fix #19162 Signed-off-by:
Andrew Thornton <art27@cantab.net> Co-authored-by:
6543 <6543@obermui.de>
-
Norwin authored
* fix idempotency of script (eg when aborting the downloads) * improve readability (user facing variables first, definitions next, statements last) * improve dependency checks * fix ignored $giteaversion variable * more logging * print usage string on incorrect usage
-
zeripath authored
* Touch mirrors on even on fail to update If a mirror fails to be synchronised it should be pushed to the bottom of the queue of the awaiting mirrors to be synchronised. At present if there LIMIT number of broken mirrors they can effectively prevent all other mirrors from being synchronized as their last_updated time will remain earlier than other mirrors. Signed-off-by:
Andrew Thornton <art27@cantab.net>
-
Lunny Xiao authored
Sanitize urls within git process descriptions. Co-authored-by:
wxiaoguang <wxiaoguang@gmail.com> Co-authored-by:
Andrew Thornton <art27@cantab.net>
-
zeripath authored
The git command by default adds a number of global arguments. These are not helpful to be displayed in the process manager and so should be skipped for default process descriptions. Signed-off-by:
Andrew Thornton <art27@cantab.net>
-
zeripath authored
The RepoIndexerTest is failing with considerable frequency due to a race inherrent in its design. This PR adjust this test to avoid the reliance on waiting for the populate repo indexer to run and forcibly adds the repo to the queue. It then flushes the queue. It may be worth separating out the tests somewhat by testing the Index function directly away from the queue however, this forceful method should solve the current problem. Signed-off-by:
Andrew Thornton <art27@cantab.net>
-
Abheek Dhawan authored
* Set the default branch for repositories generated from templates * Allows default branch to be set through the API for repos generated from templates * Update swagger API template * Only set default branch to the one from the template if not specified * Use specified default branch if it exists while generating git commits Fix #19082 Co-authored-by:
John Olheiser <john.olheiser@gmail.com> Co-authored-by:
zeripath <art27@cantab.net>
-
GiteaBot authored
-
- 26 Mar, 2022 4 commits
-
-
zeripath authored
Change all cron tasks to make them no notice on success default. Instead if a user wants notices on success they need to add NOTICE_ON_SUCCESS=true instead. ##
⚠ BREAKING⚠ This changes the cron config so that notices on success are no longer set by default and breaks NO_SUCCESS_NOTICE settings. Instead users who want notices on success must set NOTICE_ON_SUCCESS=true instead. Signed-off-by:Andrew Thornton <art27@cantab.net> * Update custom/conf/app.example.ini Co-authored-by:
Norwin <noerw@users.noreply.github.com> Co-authored-by:
Norwin <noerw@users.noreply.github.com>
-
zeripath authored
* Add auto logging of goroutine pid label This PR uses unsafe to export the hidden runtime_getProfLabel function from the runtime package and then casts the result to a map[string]string. We can then interrogate this map to get the pid label from the goroutine allowing us to log it with any logging request. Reference #19202 Signed-off-by:
Andrew Thornton <art27@cantab.net>
-
gesangtome authored
* Check go and nodejs version by go.mod and package.json * Update Go official site URL Co-authored-by:
wxiaoguang <wxiaoguang@gmail.com>
-
KN4CK3R authored
This PR adds a middleware which sets a ContextUser (like GetUserByParams before) in a single place which can be used by other methods. For routes which represent a repo or org the respective middlewares set the field too. Also fix a bug in modules/context/org.go during refactoring.
-
- 25 Mar, 2022 3 commits
-
-
Nulo authored
Co-authored-by:
Lauris BH <lauris@nix.lv>
-
zeripath authored
Use pprof labelling to help identify goroutines with stacks. Signed-off-by:
Andrew Thornton <art27@cantab.net>
-
GiteaBot authored
-
- 24 Mar, 2022 3 commits
-
-
Robert Kaussow authored
* Bump goldmark to v1.4.11 * add testcase Signed-off-by:
Andrew Thornton <art27@cantab.net> Co-authored-by:
Andrew Thornton <art27@cantab.net>
-
dependabot[bot] authored
-
6543 authored
* Changelog for 1.16.5 (#19189) * bump version
-