Restore snapshot or unistall packages for undo devs

If it doesn't relate to Debian, but you still want to share it, please do it here
Post Reply
Message
Author
User avatar
bester69
Posts: 1900
Joined: 2015-04-02 13:15
Been thanked: 1 time

Restore snapshot or unistall packages for undo devs

#1 Post by bester69 »

Hi,
How do you do when you need to build an application and it make you to install dozens of devs packages.. that you want to get rif of later.

Since I use btrfs I hardly ever unistall anything.. just use rollback snapshot sytem to prevent leave any unfit package forgotten... but i wondered if you dont consider that's a properly way to proceed...or you do the same thing?
bester69 wrote:You wont change my mind when I know Im right, Im not an ...

User avatar
sickpig
Posts: 589
Joined: 2019-01-23 10:34

Re: Restore snapshot or unistall packages for undo devs

#2 Post by sickpig »

Systemd-nspawn containers.

User avatar
bester69
Posts: 1900
Joined: 2015-04-02 13:15
Been thanked: 1 time

Re: Restore snapshot or unistall packages for undo devs

#3 Post by bester69 »

sickpig wrote:Systemd-nspawn containers.
Interesting, this is a new linux technology..isnt it?... is it easy to use and deploy? ..i know how to use chroot..I will take it a look later..

thanks. :) oink!!; oink!! :lol:
bester69 wrote:You wont change my mind when I know Im right, Im not an ...

sgosnell
Posts: 975
Joined: 2011-03-14 01:49

Re: Restore snapshot or unistall packages for undo devs

#4 Post by sgosnell »

If I really want to get rid of a package, I remove it with the --purge option, then run

Code: Select all

apt autoremove
That removes the unneeded dependencies the install pulled in, provided they aren't needed by something I installed after the first one.
Take my advice, I'm not using it.

neuraleskimo
Posts: 195
Joined: 2019-03-12 23:26

Re: Restore snapshot or unistall packages for undo devs

#5 Post by neuraleskimo »

bester69 wrote:
sickpig wrote:Systemd-nspawn containers.
Interesting, this is a new linux technology..isnt it?... is it easy to use and deploy? ..i know how to use chroot..I will take it a look later..
I want to second the pig! Containers are the way to go. Yes, they are easy to use and deploy. I am not advocating a specific technology, but if you want to try Docker, I have a container for C/C++ development that you can use as a starting point or as an example. https://github.com/tonywalker1

Good luck!
Black Lives Matter

User avatar
stevepusser
Posts: 12408
Joined: 2009-10-06 05:53
Has thanked: 7 times
Been thanked: 5 times

Re: Restore snapshot or unistall packages for undo devs

#6 Post by stevepusser »

Or build them with pbuilder or sbuild, both of which don't touch your own system packages, (mostly, some packages require dev package installs on your system for the cleaning step). :D

You can also use Timeshift instead of btrfs snapshots.
MX Linux packager and developer

User avatar
bester69
Posts: 1900
Joined: 2015-04-02 13:15
Been thanked: 1 time

Re: Restore snapshot or unistall packages for undo devs

#7 Post by bester69 »

stevepusser wrote:Or build them with pbuilder or sbuild, both of which don't touch your own system packages, (mostly, some packages require dev package installs on your system for the cleaning step). :D

You can also use Timeshift instead of btrfs snapshots.
I believed Timeshift was a gui for btrfs or rsync hardlinks backup restoring..what did I miss?


Very interesting, there seems to be a lot of good Solutions... I think I will try to learn Systemd-nspawn containers, to me looks like a more practical tool for many things,,



Thanks to all, for your help and opinions :o ..
bester69 wrote:You wont change my mind when I know Im right, Im not an ...

User avatar
Head_on_a_Stick
Posts: 13450
Joined: 2014-06-01 17:46
Location: /dev/chair

Re: Restore snapshot or unistall packages for undo devs

#8 Post by Head_on_a_Stick »

bester69 wrote:
sickpig wrote:Systemd-nspawn containers.
Interesting, this is a new linux technology..isnt it?... is it easy to use and deploy? ..i know how to use chroot..I will take it a look later..
systemd-nspawn just offers a systemd interface for a chroot container, it is nothing new.

EDIT: I'm lazy so I don't bother with sbuild, I just package up the software and use this to install the build dependencies:

Code: Select all

# mk-build-deps --install --remove
Then remove them when $package is built:

Code: Select all

# aptitude purge $package-build-deps
Black Lives Matter

Debian buster-backports ISO image: for new hardware support

cuckooflew
Posts: 681
Joined: 2018-05-10 19:34
Location: Some where out west

Re: Restore snapshot or unistall packages for undo devs

#9 Post by cuckooflew »

sickpig wrote:Systemd-nspawn containers.
https://wiki.debian.org/nspawn
Please Read What we expect you have already Done
Search Engines know a lot, and
"If God had wanted computers to work all the time, He wouldn't have invented RESET buttons"
and
Just say NO to help vampires!

Post Reply