Wayne Starr
3c07ed0911
Remove semver compatible flag and change pypi to an array of test cases ( #21708 ) ( #21729 )
...
Backport (#21708 )
This addresses #21707 and adds a second package test case for a
non-semver compatible version (this might be overkill though since you
could also edit the old package version to have an epoch in front and
see the error, this just seemed more flexible for the future).
Co-authored-by: KN4CK3R <admin@oldschoolhack.me>
2 years ago
Wayne Starr
995ae06a6e
Allow for resolution of NPM registry paths that match upstream ( #21568 ) ( #21723 )
...
Backport (#21568 )
This PR fixes issue #21567 allowing for package tarball URLs to match
the upstream registry (and GitLab/JFrog Artifactory URLs). It uses a
regex to parse the filename (which contains the NPM version) and does a
fuzzy search to pull it out. The regex was built/expanded from
http://json.schemastore.org/package ,
https://github.com/Masterminds/semver , and
https://docs.npmjs.com/cli/v6/using-npm/semver and is testable here:
https://regex101.com/r/OydBJq/5
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
2 years ago
Wayne Starr
14342047ad
Allow local package identifiers for PyPI packages ( #21690 ) ( #21726 )
...
Backport (#21690 )
Fixes #21683
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
Co-authored-by: KN4CK3R <admin@oldschoolhack.me>
2 years ago
KN4CK3R
5bc3fbd511
Fix package access for admins and inactive users ( #21580 ) ( #21592 )
...
Backport of #21580
Co-authored-by: Lauris BH <lauris@nix.lv>
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
2 years ago
eleith
169c08e20a
support binary deploy in npm packages ( #21589 )
...
backport of #21372 for v1.17.4
-------------------
npm package.json supports binary packaging:
https://docs.npmjs.com/cli/v8/configuring-npm/package-json#bin
the npm registry documents that the binary references will be attached
to the abbreviated version object:
https://github.com/npm/registry/blob/master/docs/responses/package-metadata.md#abbreviated-version-object
unfortunately their api documentation leaves this out:
https://github.com/npm/registry/blob/master/docs/responses/package-metadata.md#abbreviated-version-objectdoc
which is likely to be the reason this was left out in gitea's initial
implementation
this response is critical for npm to install the binary in the .bin
folder so as to be included on the users default bin path, resulting in
immediate access to any binaries provided by the package
i have tested upload and installing through npm and can confirm the npm
registry now responds with bin in the version metadata and results in
the binary being available after install.
this fixes https://github.com/go-gitea/gitea/issues/21303
Co-authored-by: eleith <online-github@eleith.com>
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
2 years ago
Hubert Wawrzyńczyk
0571ddc368
Case-insensitive NuGet symbol file GUID ( #21409 ) ( #21575 )
...
Backport of #21409
Co-authored-by: techknowlogick <techknowlogick@gitea.io>
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
2 years ago
KN4CK3R
46053c092d
Enforce grouped NuGet search results ( #21442 ) ( #21480 )
...
Backport of #21442
2 years ago
KN4CK3R
c83a05f114
Set SemverCompatible to false for Conan packages ( #21275 ) ( #21366 )
...
Backport of #21275
2 years ago
KN4CK3R
a3c75ac438
Make NuGet service index publicly accessible ( #21242 ) ( #21277 )
...
Backport of #21242
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
Co-authored-by: 6543 <6543@obermui.de>
2 years ago
KN4CK3R
c571ac6fd3
Allow uppercase ASCII alphabet in PyPI package names ( #21095 ) ( #21217 )
...
Backport of #21095
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
2 years ago
José Carlos
bd1412c3af
Add Dev, Peer and Optional dependencies to npm PackageMetadataVersion ( #21017 ) ( #21044 )
...
Backport #21017
Set DevDependencies, PeerDependencies & OptionalDependencies in npm package metadatas
Fix https://github.com/go-gitea/gitea/issues/21013
2 years ago
KN4CK3R
c1889f5b01
Allow multiple metadata files for Maven packages ( #20674 ) ( #20916 )
...
* Allow file overwrite for meta files.
* Added tests.
* lint
Co-authored-by: Lauris BH <lauris@nix.lv>
Co-authored-by: techknowlogick <techknowlogick@gitea.io>
Co-authored-by: Lauris BH <lauris@nix.lv>
Co-authored-by: techknowlogick <techknowlogick@gitea.io>
2 years ago
KN4CK3R
67701771af
Add support for NuGet API keys ( #20721 ) ( #20734 )
...
Co-authored-by: delvh <dev.lh@web.de>
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
Co-authored-by: Lauris BH <lauris@nix.lv>
2 years ago
KN4CK3R
113d13a026
Keep download count on Container tag overwrite ( #20728 ) ( #20735 )
...
Co-authored-by: 6543 <6543@obermui.de>
2 years ago
KN4CK3R
65176fdaf3
Send correct NuGet status codes ( #20647 ) ( #20677 )
...
* Fixed status codes.
* Fixed status codes.
2 years ago
6543
97a8c96c5b
Add Docker /v2/_catalog endpoint ( #20469 ) ( #20556 )
...
* 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: KN4CK3R <admin@oldschoolhack.me>
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
Co-authored-by: Lauris BH <lauris@nix.lv>
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
2 years ago
6543
ae86a0bc9f
packages/generic: Do not restrict package versions to SemVer ( #20414 ) ( #20531 )
...
There are existing packages out there whose version do not conform to SemVer, yet, one would like to have them available in a generic package repository. To this end, remove the SemVer restriction on package versions when using the Generic package registry, and replace it with a check that simply makes sure the version isn't empty.
Signed-off-by: Gergely Nagy <me@gergo.csillger.hu>
Co-authored-by: KN4CK3R <admin@oldschoolhack.me>
Co-authored-by: 6543 <6543@obermui.de>
Co-authored-by: Gergely Nagy <algernon@users.noreply.github.com>
2 years ago
KN4CK3R
9ea9206406
ContainerRegistry - removed Basic Auth header ( #19735 )
...
* Removed Basic Auth header.
* Fixed test.
3 years ago
KN4CK3R
4691e59828
Skip duplicated layers. ( #19624 )
3 years ago
KN4CK3R
18727df73a
Add Helm Chart registry ( #19406 )
3 years ago
KN4CK3R
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
3 years ago
KN4CK3R
08d199245a
Fix container download counter ( #19287 )
...
* Increment counter on manifest download.
* Refactor GetPackageFileStream method.
3 years ago
KN4CK3R
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>
3 years ago