Would like a "mixer bundle remove --all" option
It would be nice to have a "remove --all" option to completely remove all bundles instead of having to name each bundle.
What is wrong with
cd /usr/share/clear/bundles
swupd bundle remove *
@icarus-sparry I'm not sure how that would solve his problem, let alone work. I believe @bktan8 wants to essentially wipe his mixbundles file. I think that sounds like a reasonable feature request. I'd say just remove the contents of mixbundles but that is an implementation detail the user doesn't need to know about.
Ah, I managed to see this as a request to remove all bundles from the OS - my mistake.
So something like
mixer bundle remove $( mixer bundle list XXXX)
instead?
That would need more processing I believe, since mixer bundle list outputs a bunch of other garbage too... /me glares at @kevincwells
That --all flag seems like a good idea to me. It shouldn't require much work to add/maintain it anyway.
I think it would be better to have a --short flag for mixer bundle list to just give the names only, so you can compose things, e.g.
mixer bundle list --short | grep -v '^R-' | xargs mixer bundle remove
to remove things which are not R packages. The --all might be the most frequent need, but it is surely not the only one.
In that case it might be better to just make bundle remove support regex?
mixer bundle remove '^(?!R-).*$'
(or something)
In that case it might be better to just make bundle remove support regex?
That is a bit too much. If you need regex support you better of using some other tool to get you what you want.
I think it would be better to have a --short flag for mixer bundle list to just give the names only
Do we have other use cases for getting the list, names only or removing them all is the only one so far?
That is a bit too much. If you need regex support you better of using some other tool to get you what you want.
Why? We can just import "regexp" and use the library.
Why? We can just import "regexp" and use the library.
Because then you need to add testing and documentation for the regex use and fix any awkward error that might appear because someone found a weird regex that breaks everything.
we don't have to re-implement regex parsing. All we have to do is pass the string to the library function. That is hardly anything more to test