BaGet
BaGet copied to clipboard
UI: Deletion of packages
Do you want to request a feature or report a bug?
Feature
What did you expect to see?
- A delete button next to a package (all versions)
- A delete button next to a package version
- A delete button for many packages, perhaps all at once
In other words, are there any high level plans for the web ui?
In other words, are there any high level plans for the web ui?
Yup! I intend to recreate most of NuGet.org's UI, only with yellow highlights 😄
yes, that is sound very good. also, if we can set a pakcage 'max version count' value, automatic delete the oldest versions... is it OK ?
@timiil see #142 for package retention
How can we manually delete packages at this point? I attempted to delete with
nuget delete MyPackage 1.0 -Source https://nuget.mydomain.com -ApiKey API-KEY
I get the warning and a prompt, and then I get this:
DELETE https://nuget.mydomain.com/api/v2/package/MyPackage/1.0
NoContent https://nuget.domain.com/api/v2/package/MyPackage/1.0 498ms
MyPackage 1.0 was deleted successfully.
But I can still see the package in the UI and the files still exist on the storage location. I would assume I can physically delete the file from the storage location, but what happens to the database entry? Isn't it index?
The whole issue with this is that I am trying to replace a package with an updated one of the same version. But I keep getting 409 - Conflict
errors, because there is an existing package.
UPDATE: So I just deleted the package from the file system, and as expected, the entry still shows up on the UI, this means the db entry needs to be deleted as well.
Deletion should be implemented, at least the code is there. The default is however, for deletions to unlist packages - not delete them.
You need to configure BaGetOptions
, which if I read this correctly is the root of the appsettings.json
.
Just adding "PackageDeletionBehavior": "HardDelete"
in the appsettings.json
, next to ApiKey
should do it for you.
I enabled the HardDelete
option, and was able to delete the package properly.
However, what about package replacement? Should not there be an option to replace packages with matching version number? Right now, even with HardDelete
set, I still get 409
when replacing the package. I read about the whole left-pad thing, and I understand it, but our organization's needs are different. It would help if the UI allowed for proper package management, but I understand it is in early stages, and it is looking GREAT!
We are currently using phpNuget, which supports deletion and replacement, but we are seeing very slow activity in the development and are looking for other options.
Thanks for your help, @LordMike .
This seems like a seperate issue - I can't find anything, but I think I once saw something along the lines of allowing replacement of packages. Because yes, BaGet is to be run in a local setting, and cater to approximately one use case.. (those that run it), so it should allow all kinds of weirdness.
I'd create an issue on it, @bkraul
Thanks for the help @LordMike!
I also needed to "clean" up my packages and searched for a way to delete some old test packages from Baget. Unfortunately theres no information on the help page (like its done with PUSH) of my Baget installation, so Im glad I found this topic! :)
I used this command to delete a package from Baget:
dotnet nuget delete mynuget 1.0.0 -s http://localhost:5000/v3/index.json -k "myapikey" --non-interactive
Is it possible to add another help page in Baget Server for this? I think this one might be an option which is used by many people.
I'd like to throw my hat in the ring as this being a really useful addition. I've been doing command-line jujitsu to remove packages, but for packages with multiple revisions this is a big PITA. Also, the removal removes the package but not its parent folder, which means I have to go behind and clean up the folder structure as well.
Loving the app btw - this is basically the only missing feature for me.
Best,
--J
However, what about package replacement? Should not there be an option to replace packages with matching version number? Right now, even with
HardDelete
set, I still get409
when replacing the package. I read about the whole left-pad thing, and I understand it, but our organization's needs are different. It would help if the UI allowed for proper package management, but I understand it is in early stages, and it is looking GREAT!
You may use "AllowPackageOverwrites": true, in the same appsettings.json, but this feature is extremely toxic. Consider applying proper versioning in your CI / CD process.
Any updates on this? We'd love to have a button to delete the package :)!
Any update?
is this project still supported?
// Push
I would love to have this feature
Any update?
push