Tiny Core Extensions > TCE Tips & Tricks

script to uninstall extension and resulting orphan dependencies

<< < (2/2)

Rich:
Hi GNUser
There are a few things that don't get cleaned up:
1. Entries for the  wbar  (/usr/local/tce.icons).
2. Desktop menu entries.
3. Changes a  /usr/local/tce.installed/ExtensionName  script may have performed.
4. Other items that I missed.

This is not a criticism since the script meets your needs. Merely a heads up to others that there may be some unexpected side effects.

GNUser:
Thank you, Rich.

I wrote this to solve a simple problem: I was in a CLI-only environment, didn't want to reboot, and wanted to remove an extension (from tce/optional/ and tce/onboot.lst) and recursively remove any orphaned dependencies that pop up as a result. The script solved this problem beautifully and is careful to remove only orphans that pop up after the extension(s) named on the command line are removed.

The minimal cleanup that the script does is just a bonus and more than enough for my purposes. But I'm glad you spoke up so that folks have an idea of what the script doesn't do.

Greg Erskine:
Hi GNUser.

Nice scripting.

I used to do similar things but eventually came to the conclusion that using the existing TC tools was the "right" way to do it, even if it required a reboot.

To me "Uninstall" means remove from .onboot.lst but do not delete the extensions from media. On piCore, there are extensions for the various versions of the RPi (single core, quad core) but are not installed during a boot but are just waiting for you to move the SD card to another RPi. I think of these extensions as "uninstalled".

Does this script work for ondemand loaded extensions?

regards
Greg

GNUser:
Thank you, Greg.

No, other than the fancy way it recursively finds new orphans, the script it pretty primitive. It only deals with tce/optional/ and tce/onboot.lst.


--- Quote from: Greg Erskine on July 26, 2019, 05:41:31 PM ---I used to do similar things but eventually came to the conclusion that using the existing TC tools was the "right" way to do it, even if it required a reboot.
--- End quote ---

But then you'll never break anything and that's no fun ;)

Navigation

[0] Message Index

[*] Previous page

Go to full version