a1ae83f36e
Workaround for container registry push/pull errors ( #21862 )
...
This PR addresses #19586
I added a mutex to the upload version creation which will prevent the
push errors when two requests try to create these database entries. I'm
not sure if this should be the final solution for this problem.
I added a workaround to allow a reupload of missing blobs. Normally a
reupload is skipped because the database knows the blob is already
present. The workaround checks if the blob exists on the file system.
This should not be needed anymore with the above fix so I marked this
code to be removed with Gitea v1.20.
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com >
2022-11-25 13:47:46 +08:00
fc7a2d5a95
Add support for HEAD requests in Maven registry ( #21834 )
...
Related #18543
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com >
2022-11-24 16:25:13 +02:00
KN4CK3R and GitHub
b2269dedf2
Fix typo in sidebar ( #21922 )
2022-11-24 18:31:32 +08:00
32db62515f
Add package registry cleanup rules ( #21658 )
...
Fixes #20514
Fixes #20766
Fixes #20631
This PR adds Cleanup Rules for the package registry. This allows to
delete unneeded packages automatically. Cleanup rules can be set up from
the user or org settings.
Please have a look at the documentation because I'm not a native english
speaker.
Rule Form

Rule List

Rule Preview

Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com >
2022-11-20 16:08:38 +02:00
044c754ea5
Add context.Context to more methods ( #21546 )
...
This PR adds a context parameter to a bunch of methods. Some helper
`xxxCtx()` methods got replaced with the normal name now.
Co-authored-by: delvh <dev.lh@web.de >
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com >
2022-11-19 16:12:33 +08:00
88d5275614
Do not allow Ghost access to limited visible user/org ( #21849 )
...
The Ghost user should not be allowed to have access to a limited visible
user/org.
Co-authored-by: Lauris BH <lauris@nix.lv >
2022-11-17 14:29:33 -05:00
KN4CK3R and GitHub
43ab9324c5
Fix setting HTTP headers after write ( #21833 )
...
The headers can't be modified after it was send to the client.
2022-11-18 01:55:15 +08:00
20674dd05d
Add package registry quota limits ( #21584 )
...
Related #20471
This PR adds global quota limits for the package registry. Settings for
individual users/orgs can be added in a seperate PR using the settings
table.
Co-authored-by: Lauris BH <lauris@nix.lv >
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com >
2022-11-09 14:34:27 +08:00
fd89c062bd
Allow local package identifiers for PyPI packages ( #21690 )
...
Fixes #21683
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com >
2022-11-07 21:35:04 +02:00
KN4CK3R and GitHub
f8f859b8fa
Alter package_version.metadata_json to LONGTEXT ( #21667 )
2022-11-03 15:28:46 +08:00
KN4CK3R
9b3e2c5450
[skip ci] Updated translations via Crowdin
2022-10-31 00:19:34 +00:00
KN4CK3R
d33b2d473c
[skip ci] Updated licenses and gitignores
2022-10-30 00:19:37 +00:00
49436c2c62
Keep languages defined in .gitattributes ( #21403 )
...
Fixes #21377
This marks all "defined" languages in the `.gitattributes` file so they
are not removed if they are not of type `programming` or `markup`.

Co-authored-by: zeripath <art27@cantab.net >
Co-authored-by: Lauris BH <lauris@nix.lv >
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com >
2022-10-29 15:04:21 +08:00
ed47d0062e
Fix Timestamp.IsZero ( #21593 )
...
Our implementation of `IsZero` can't work. An "empty" timestamp (= 0)
calls `time.Unix(int64(ts), 0).IsZero()` which is always `false`. Only
`time.Time{}.IsZero()` is `true`.
We call this method ~~only at one place~~ and there the value
(`UpdatedUnix`) should be always != 0 so this PR may not have
consequences.
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com >
2022-10-26 21:34:44 +08:00
KN4CK3R and GitHub
5c2089a01d
Change commits-table column width ( #21564 )
...
Fixes #21561
Before

After

2022-10-25 18:00:37 +01:00
7c11a73833
Fix package access for admins and inactive users ( #21580 )
...
I noticed an admin is not allowed to upload packages for other users
because `ctx.IsSigned` was not set.
I added a check for `user.IsActive` and `user.ProhibitLogin` too because
both was not checked. Tests enforce this now.
Co-authored-by: Lauris BH <lauris@nix.lv >
2022-10-24 22:23:25 +03:00
KN4CK3R and GitHub
876ee8c3cd
Allow package version sorting ( #21453 )
2022-10-23 09:18:15 +08:00
154efa59a5
Prevent Authorization header for presigned LFS urls ( #21531 )
...
Fixes #21525
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com >
2022-10-22 21:36:44 +08:00
1887c95254
Decouple HookTask from Repository ( #17940 )
...
At the moment a repository reference is needed for webhooks. With the
upcoming package PR we need to send webhooks without a repository
reference. For example a package is uploaded to an organization. In
theory this enables the usage of webhooks for future user actions.
This PR removes the repository id from `HookTask` and changes how the
hooks are processed (see `services/webhook/deliver.go`). In a follow up
PR I want to remove the usage of the `UniqueQueue´ and replace it with a
normal queue because there is no reason to be unique.
Co-authored-by: 6543 <6543@obermui.de >
2022-10-21 18:21:56 +02:00
KN4CK3R
99597dd76a
[skip ci] Updated translations via Crowdin
2022-10-20 00:20:58 +00:00
KN4CK3R and GitHub
1713beb73b
Suppress ExternalLoginUserNotExist error ( #21504 )
...
Fixes #21202
Closes #21276
An `ExternalLoginUser` is not mandatory if the current user account was
created with/by the external login source.
2022-10-19 20:07:21 +01:00
c3b2e44392
Add team member invite by email ( #20307 )
...
Allows to add (not registered) team members by email.
related #5353
Invite by mail:

Pending invitations:

Email:

Join form:

Co-authored-by: Jack Hay <jjphay@gmail.com >
2022-10-19 14:40:28 +02:00
KN4CK3R
ea08559045
[skip ci] Updated translations via Crowdin
2022-10-18 00:21:08 +00:00
a37e8b275d
Do not send notifications for draft releases ( #21451 )
...
Fixes #21448
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com >
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com >
Co-authored-by: 6543 <6543@obermui.de >
2022-10-17 17:33:27 -04:00
a577214760
Add some api integration tests ( #18872 )
...
depends on #18871
Added some api integration tests to help testing of #18798 .
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com >
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com >
Co-authored-by: zeripath <art27@cantab.net >
Co-authored-by: techknowlogick <techknowlogick@gitea.io >
2022-10-18 00:23:27 +08:00
11d3677818
Enforce grouped NuGet search results ( #21442 )
...
Fixes #21434
Added tests to enforce this behaviour.
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com >
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com >
2022-10-17 01:18:09 +08:00
cad9adeff4
Display total commit count in hook message ( #21400 )
...
Fixes #21379
The commits are capped by `setting.UI.FeedMaxCommitNum` so
`len(commits)` is not the correct number. So this PR adds a new
`TotalCommits` field.
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com >
2022-10-17 00:22:34 +08:00
0e58201d1a
Add support for Chocolatey/NuGet v2 API ( #21393 )
...
Fixes #21294
This PR adds support for NuGet v2 API.
Co-authored-by: Lauris BH <lauris@nix.lv >
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com >
2022-10-13 18:19:39 +08:00
444e9df465
Contribution guidelines ( #21425 )
...
Some changes to the contribution guidelines.
- I removed the `Large Character Comments` part because I think they are
bad design. They are used in big files to group sections of code. This
code should be organized into individual files.
- Updated some paths.
- Added `Documentation` because our documentation is not good at the
moment. We should enforce documentation of newly added features to help
our users.
Co-authored-by: techknowlogick <techknowlogick@gitea.io >
2022-10-12 12:17:28 -04:00
0e57ff7eee
Add generic set type ( #21408 )
...
This PR adds a generic set type to get rid of maps used as sets.
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com >
2022-10-12 13:18:26 +08:00
4dc3b2ec57
Use Name instead of DisplayName in LFS Lock ( #21415 )
...
Fixes #21268
Co-authored-by: techknowlogick <techknowlogick@gitea.io >
2022-10-11 21:03:15 -04:00
KN4CK3R and GitHub
8752d89be7
Redirect to new repository owner ( #21398 )
...
Fixes #17655
If you rename `user1` to `user2` and visit `/user1` you get redirected
to `/user2`. But if you visit `/user1/repo` you just get a 404 error.
With this PR the user is redirected to `/user2/repo`.
2022-10-11 19:54:44 +08:00
KN4CK3R and GitHub
223556073c
Show private data in feeds ( #21369 )
...
Show private data in feeds for admins and matching users.
2022-10-07 22:06:04 +01:00
69fc510d6d
Add GET and DELETE endpoints for Docker blob uploads ( #21367 )
...
This PR adds support for
https://docs.docker.com/registry/spec/api/#get-blob-upload
https://docs.docker.com/registry/spec/api/#delete-blob-upload
Both are not required by the OCI spec but some clients call these
endpoints.
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com >
2022-10-07 23:30:59 +08:00
KN4CK3R and GitHub
30ca91666e
Set SemverCompatible to false for Conan packages ( #21275 )
...
Fixes #21250
Related #20414
Conan packages don't have to follow SemVer.
The migration fixes the setting for all existing Conan and Generic
(#20414 ) packages.
2022-10-07 12:22:05 +08:00
KN4CK3R and GitHub
b7309b8ccb
Add name field for org api ( #21270 )
...
related #21205
The field `UserName` is not really usefull for an organization.
This adds a second `Name` field.
The [GitHub API](https://docs.github.com/en/rest/orgs/orgs#get-an-organization ) uses `name` too. `UserName` should be deprecated then.
2022-09-29 05:27:33 +02:00
KN4CK3R and GitHub
904b324716
Fix empty container layer history and UI ( #21251 )
...
Fixes #21248
2022-09-27 15:03:24 +02:00
0c8ce71188
Make NuGet service index publicly accessible ( #21242 )
...
Addition to #20734 , Fixes #20717
The `/index.json` endpoint needs to be accessible even if the registry
is private. The NuGet client uses this endpoint without
authentification.
The old fix only works if the NuGet cli is used with `--source <name>`
but not with `--source <url>/index.json`.
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com >
2022-09-24 23:17:08 +08:00
KN4CK3R
301d84e83a
[skip ci] Updated translations via Crowdin
2022-09-23 00:20:55 +00:00
f52fe82add
Use absolute links in feeds ( #21229 )
...
fixes #20864
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com >
Co-authored-by: techknowlogick <techknowlogick@gitea.io >
2022-09-21 16:51:42 -04:00
0a9a86b943
Respect REQUIRE_SIGNIN_VIEW for packages ( #20873 )
...
Fix #20863
When REQUIRE_SIGNIN_VIEW = true, even with public repositories, you can only see them after you login. The packages should not be accessed without login.
Co-authored-by: Lauris BH <lauris@nix.lv >
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com >
2022-09-21 21:01:18 +08:00
1b630ff7cd
Fix user visible check ( #21210 )
...
Fixes #21206
If user and viewer are equal the method should return true.
Also the common organization check was wrong as `count` can never be
less then 0.
Co-authored-by: 6543 <6543@obermui.de >
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com >
2022-09-20 15:59:20 +08:00
KN4CK3R and GitHub
43c10def68
Fix CSV diff for added/deleted files ( #21189 )
...
Fixes #21184
Regression of #19552
Instead of using `GetBlobByPath` I use the already existing instances.
We need more information from #19530 if that error is still present.
2022-09-17 10:45:32 +08:00
KN4CK3R and GitHub
ef40324c43
Display image digest for container packages ( #21170 )
...
fixes #21160
2022-09-14 22:45:13 +02:00
KN4CK3R and GitHub
5933f04094
Skip dirty check for team forms ( #21154 )
...
The dirty check is not usefull for these forms.
2022-09-14 13:24:39 +02:00
KN4CK3R and GitHub
8b8bdb30fb
Allow uppercase ASCII alphabet in PyPI package names ( #21095 )
...
The PyPI name regexp is too restrictive and only permits lowercase characters. This PR adjusts the regexp to add in support for uppercase characters.
Fix #21014
2022-09-07 21:18:51 +01:00
KN4CK3R and GitHub
5bc73ca666
Delete unreferenced packages when deleting a package version ( #20977 )
...
Delete a package if its last version got deleted. Otherwise removing the owner works only after the clean up job ran.
Fix #20969
2022-09-03 17:01:00 +01:00
KN4CK3R and GitHub
4bd3b05b62
Redirect if user does not exist ( #20981 )
2022-08-29 15:44:39 +02:00
41c76ad714
Add support for Vagrant packages ( #20930 )
...
* Add support for Vagrant boxes.
* Add authentication.
* Add tests.
* Add integration tests.
* Add docs.
* Add icons.
* Update routers/api/packages/api.go
Co-authored-by: Lauris BH <lauris@nix.lv >
Co-authored-by: 6543 <6543@obermui.de >
2022-08-29 15:04:45 +08:00
dc0253b063
Replace ServeStream with ServeContent ( #20903 )
...
* Replace ServeStream with ServeContent.
* Update modules/timeutil/timestamp.go
Co-authored-by: delvh <dev.lh@web.de >
Co-authored-by: delvh <dev.lh@web.de >
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com >
Co-authored-by: techknowlogick <techknowlogick@gitea.io >
2022-08-25 12:05:21 -04:00
9e0c43777e
Display total blob size of a package version. ( #20927 )
...
Co-authored-by: techknowlogick <techknowlogick@gitea.io >
2022-08-24 13:48:33 +08:00
103b94f96e
Display all files. ( #20917 )
...
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com >
Co-authored-by: techknowlogick <techknowlogick@gitea.io >
2022-08-23 21:39:25 -04:00
KN4CK3R and GitHub
1939e87348
Enhance package date display ( #20928 )
...
* Use better date display.
* Update templates/package/view.tmpl
2022-08-23 21:39:00 -04:00
7009eb9a24
Add support for NuGet API keys ( #20721 )
...
* Add support for NuGet API key.
* lint
* Apply suggestions from code review
Co-authored-by: delvh <dev.lh@web.de >
Co-authored-by: delvh <dev.lh@web.de >
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com >
Co-authored-by: Lauris BH <lauris@nix.lv >
2022-08-09 17:36:49 +03:00
920481340b
Keep download count on Container tag overwrite ( #20728 )
...
Co-authored-by: 6543 <6543@obermui.de >
2022-08-09 16:47:57 +03:00
KN4CK3R and GitHub
fba20550f9
Add support for npm unpublish ( #20688 )
2022-08-09 15:23:43 +08:00
cc6927b2d8
Allow multiple files in generic packages ( #20661 )
...
* Allow multiple files in generic packages.
* Add deletion of a single file.
* Update docs.
* Change version check.
Co-authored-by: silverwind <me@silverwind.io >
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com >
2022-08-09 12:39:24 +08:00
KN4CK3R and GitHub
2b101994a6
Fix init mail render logic ( #20704 )
...
This bug affects tests which are sending emails (#20307 ). Some tests reinitialise the web routes (like `TestNodeinfo`) which messed up the mail templates. There is no reason why the templates should be loaded in the routes method.
2022-08-08 20:04:28 +02:00
64c371a167
Update maven deploy docs ( #20691 )
...
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com >
2022-08-07 21:58:03 +08:00
f55af4675c
Add support for Pub packages ( #20560 )
...
* Added support for Pub packages.
* Update docs/content/doc/packages/overview.en-us.md
Co-authored-by: Gergely Nagy <algernon@users.noreply.github.com >
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com >
Co-authored-by: Gergely Nagy <algernon@users.noreply.github.com >
Co-authored-by: Lauris BH <lauris@nix.lv >
2022-08-07 18:09:54 +08:00
KN4CK3R
61aafb9c7d
[skip ci] Updated translations via Crowdin
2022-08-06 00:20:54 +00:00
baf374a3a4
Allow multiple metadata files for Maven packages ( #20674 )
...
* Allow file overwrite for meta files.
* Added tests.
* lint
Co-authored-by: Lauris BH <lauris@nix.lv >
Co-authored-by: techknowlogick <techknowlogick@gitea.io >
2022-08-05 15:00:47 -04:00
ba0a0d31c9
Use correct field name. ( #20675 )
...
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com >
2022-08-05 14:49:03 +08:00
KN4CK3R
0f767e799c
[skip ci] Updated translations via Crowdin
2022-08-05 00:20:59 +00:00
KN4CK3R and GitHub
b678d1adae
Use correct context to get package content ( #20673 )
2022-08-04 16:14:47 -05:00
KN4CK3R and GitHub
99fc419855
Send correct NuGet status codes ( #20647 )
...
* Fixed status codes.
* Fixed status codes.
2022-08-03 11:22:32 -04:00
631539c104
Fix package upload for files >32mb ( #20622 )
...
* Rewind file before first read.
* Added tests.
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com >
2022-08-02 21:35:48 +08:00
KN4CK3R and GitHub
66b623c2aa
Update login methods in package docs ( #20561 )
2022-07-31 15:41:25 +02:00
KN4CK3R and GitHub
a846bfefd8
Extended permission checks. ( #20517 )
2022-07-28 21:04:03 +08:00
86e5268c39
Add Docker /v2/_catalog endpoint ( #20469 )
...
* Added properties for packages.
* Fixed authenticate header format.
* Added _catalog endpoint.
* Check owner visibility.
* Extracted condition.
* Added test for _catalog.
Co-authored-by: 6543 <6543@obermui.de >
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com >
Co-authored-by: Lauris BH <lauris@nix.lv >
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com >
2022-07-28 11:59:39 +08:00
KN4CK3R and GitHub
a3d55ac523
Hide internal package versions ( #20492 )
...
* Hide internal versions from most searches.
* Added test.
2022-07-27 09:59:10 +08:00
KN4CK3R and GitHub
690272d2e2
Fix Ruby package parsing by removed unused email field ( #20470 )
2022-07-25 02:52:14 +02:00
KN4CK3R and GitHub
7690de56f7
Simplify visibility checks ( #20406 )
...
Was looking into the visibility checks because I need them for something different and noticed the checks are more complicated than they have to be.
The rule is just: user/org is visible if
- The doer is a member of the org, regardless of the org visibility
- The doer is not restricted and the user/org is public or limited
2022-07-21 11:41:50 +01:00
KN4CK3R and GitHub
e24b0fc7b8
Changed scroll to auto for some UI elements. ( #20294 )
...
Addition to: Show scrollbar when necessary #20142
Fixes the "empty" scrollbars with Firefox.
2022-07-10 20:58:26 +08:00
KN4CK3R and GitHub
ce52514762
Fix org package owner permissions ( #19742 )
...
Old code did not respect owner visibility and the organization access calculation was wrong if the user was not a member.
2022-05-19 17:56:45 +02:00
KN4CK3R and GitHub
9ea9206406
ContainerRegistry - removed Basic Auth header ( #19735 )
...
* Removed Basic Auth header.
* Fixed test.
2022-05-17 19:58:42 +08:00
KN4CK3R and GitHub
3da9dafc60
Add Webfinger endpoint ( #19462 )
...
This adds the [Webfinger](https://webfinger.net/ ) endpoint for federation.
Supported schemes are `acct` and `mailto`. The profile and avatar url are returned as metadata.
2022-05-09 20:20:21 +02:00
KN4CK3R and GitHub
a9ca4b4100
Calculate filename hash only once ( #19654 )
...
* Calculate hash only once.
* remove unused Sha1 template helper function, use ctx.Data["FileNameHash"]
* fix unit tests
2022-05-09 00:29:50 +02:00
KN4CK3R and GitHub
8adba93498
Hide private repositories in packages ( #19584 )
2022-05-07 18:21:15 +02:00
KN4CK3R and GitHub
4691e59828
Skip duplicated layers. ( #19624 )
2022-05-05 23:02:09 +01:00
KN4CK3R and GitHub
e5c6c001c5
Permalink files In PR diff ( #19534 )
2022-04-29 12:26:52 +02:00
e4274f640c
Allow package dump skipping ( #19506 )
...
* Added addReader to support verbose.
* Allow skipping packages.
* Updated docs.
* Update cmd/dump.go
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com >
Co-authored-by: 6543 <6543@obermui.de >
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com >
2022-04-26 16:30:51 -04:00
KN4CK3R and GitHub
18727df73a
Add Helm Chart registry ( #19406 )
2022-04-19 12:55:35 -04:00
KN4CK3R and GitHub
6d51b9f615
Fixed registry host value. ( #19363 )
2022-04-10 19:57:36 +08:00
c003491cfb
Allow package linking to private repository ( #19348 )
...
* Display private repos too.
* lint
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com >
2022-04-09 23:57:37 +08:00
KN4CK3R and GitHub
5e242e021b
Package registry changes ( #19305 )
...
* removed debug logs
* fixed SELECT
* removed unneeded error type
* use common SearchVersions method
* remove empty container upload versions
* return err
2022-04-06 03:32:09 +02:00
KN4CK3R and GitHub
08d199245a
Fix container download counter ( #19287 )
...
* Increment counter on manifest download.
* Refactor GetPackageFileStream method.
2022-04-01 01:08:32 +02:00
1d332342db
Add Package Registry ( #16510 )
...
* 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 >
2022-03-30 16:42:47 +08:00
KN4CK3R and GitHub
59b867dc2d
Add ContextUser to http request context ( #18798 )
...
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.
2022-03-26 17:04:22 +08:00
KN4CK3R and GitHub
3f280f89e7
Update HTTP status codes to modern codes ( #18063 )
...
* 2xx/3xx/4xx/5xx -> http.Status...
* http.StatusFound -> http.StatusTemporaryRedirect
* http.StatusMovedPermanently -> http.StatusPermanentRedirect
2022-03-23 12:54:07 +08:00
80fd25524e
Renamed ctx.User to ctx.Doer. ( #19161 )
...
Co-authored-by: 6543 <6543@obermui.de >
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com >
2022-03-22 15:03:22 +08:00
KN4CK3R and GitHub
c88f2e2acc
Handle email address not exist. ( #19089 )
2022-03-15 10:18:39 +01:00
KN4CK3R and GitHub
f3cbdee38e
Don't clean up hardcoded tmp ( #18983 )
...
* Don't clean up hardcoded `tmp`.
* Fixed import.
2022-03-02 23:50:29 +01:00
f8898c30dc
Add note to GPG key response if user has no keys ( #18961 )
...
* Prevent invalid key response.
* Display note instead of 404 response.
* Fixed test.
Co-authored-by: zeripath <art27@cantab.net >
Co-authored-by: 6543 <6543@obermui.de >
Co-authored-by: techknowlogick <techknowlogick@gitea.io >
2022-03-02 11:32:18 -05:00
KN4CK3R and GitHub
5b0cdd6155
Set is_empty in fixtures ( #18869 )
2022-02-26 01:15:25 -05:00
9d7a431b71
Set is_private in fixtures. ( #18868 )
...
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com >
2022-02-25 16:22:20 -05:00
KN4CK3R and GitHub
159c3f48af
Generate coverage with sqlite. ( #18813 )
2022-02-19 10:28:43 +08:00
e30b20dc68
Show OAuth callback error message ( #18185 )
...
* Show callback error message.
* lint
* Use error code to display a message.
Co-authored-by: 6543 <6543@obermui.de >
Co-authored-by: Lauris BH <lauris@nix.lv >
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com >
2022-01-07 21:02:09 +00:00
KN4CK3R and GitHub
bf7b083cfe
Add replay of webhooks. ( #18191 )
2022-01-05 15:00:20 -06:00
KN4CK3R and GitHub
67d7ad681a
Fix wrong redirect on org labels ( #18128 )
2021-12-30 07:44:42 +01:00