Refracta Development, Scripts, etc.
Post a reply
meandean

- meandean
- Posts: 392
- Joined: Wed Mar 09, 2011 5:16 am

## fiddlin with repsit

Sat Mar 23, 2013 2:29 am

not much time to fiddle lately but messed with repsit a while
might find it useful...or not...
http://sourceforge.net/projects/kyloris ... psit-dean/
fsmithred

- fsmithred
- Posts: 2101
- Joined: Wed Mar 09, 2011 9:13 pm

## Re: fiddlin with repsit

Sat Mar 23, 2013 12:00 pm

Listing the packages individually eliminates the problem of which packages to group together. I think I like that,
Youtube viewer is not from the repo and was installed from a .deb file. It won't be installed by that script.
It would be nice if the script could show which of those packages are installed or not, to save you from trying to install something that's already installed or remove something that isn't there. I never spent much time trying to figure out how to do that.
Oh, I just got an idea for that last part. A third 'long function' that checks the installation status of selected packages, with the same list of packages as the other functions. Have to figure out how to get the information into a zenity window (and maybe a yad window.)
fsmithred

- fsmithred
- Posts: 2101
- Joined: Wed Mar 09, 2011 9:13 pm

## Re: fiddlin with repsit

Sat Mar 23, 2013 8:20 pm

Added a function to let you check if a package is installed or not. Crude, but it works.
https://gist.github.com/fsmithred/5229197
meandean

- meandean
- Posts: 392
- Joined: Wed Mar 09, 2011 5:16 am

## Re: fiddlin with repsit

Mon Mar 25, 2013 12:19 am

> Youtube viewer is not from the repo and was installed from a .deb file. It won't be installed by that script.

To be honest I hadnt thought about installing. Installing totally slipped my thought process. What can I say, my mind hasn't been right since the dilaudid! I just thought something a user could run to quickly have a slimmer refracta would be useful.

> It would be nice if the script could show which of those packages are installed or not,

I wondered about that too but it is certainly beyond me .
I also thought maybe an autoremove and aptitude purge ~c would be cool but maybe that belongs in a refracta-tweak tool instead. ....hint....hint...
I cleaned up the packages a bit...still no descriptions though...
http://sourceforge.net/projects/kyloris ... psit-dean/
fsmithred

- fsmithred
- Posts: 2101
- Joined: Wed Mar 09, 2011 9:13 pm

## Re: fiddlin with repsit

Tue Mar 26, 2013 1:32 am

You want a graphical way to do some housecleaning? Make a list.
-Remove orphaned packages
-Remove leftover config files
-Remove packages that are no longer needed
-Remove package files to clear space
-Show cool output from obscure commands (e.g. list packages from d-m, list non-free packages, list packages installed on my dog's birthday)
Then we just dress it up in zenity/yad.
Repsit pretty much just needs descriptions and probably the displayed lists should be alphabetized.
meandean

- meandean
- Posts: 392
- Joined: Wed Mar 09, 2011 5:16 am

## Re: fiddlin with repsit

Wed Mar 27, 2013 1:38 pm

pretty good list so far...you have out thought me
I will work on repsit hopefully today and test it a bit more too
meandean

- meandean
- Posts: 392
- Joined: Wed Mar 09, 2011 5:16 am

## Re: fiddlin with repsit

Sat Mar 30, 2013 9:17 am

better late than never - http://sourceforge.net/projects/kyloris ... psit-dean/
looks like it frees/adds up about 300mb of disk space without leaving anything dangling
I would like to see it run aptitude ~c for a good clean uninstall of configs too but whatevahhh
fsmithred

- fsmithred
- Posts: 2101
- Joined: Wed Mar 09, 2011 9:13 pm

## Re: fiddlin with repsit

Sat Mar 30, 2013 11:55 am

It's not late - wheezy is still in testing.
It's possible to add one line to remove_packages () to remove the config files, but this way, you wouldn't know what it was doing:

Code:
  `zenity --question --text="$(aptitude -s install ${install_list[@]} &)"
  if [[ $? = 0 ]] ; then
  aptitude -y install ${install_list[@]} | tee >(zenity --progress --pulsate)
  aptitude -y purge ~c | tee>(zenity --progress --pulsate)
  else
  echo "You said no."
  exit 0
  fi`

Or, we could add another function, and then you get to see the list and choose whether to purge or not.
meandean

- meandean
- Posts: 392
- Joined: Wed Mar 09, 2011 5:16 am

## Re: fiddlin with repsit

Sat Mar 30, 2013 3:21 pm

probably better to leave it to the user to cleanup anyway
either way works for me
up to you
fsmithred

- fsmithred
- Posts: 2101
- Joined: Wed Mar 09, 2011 9:13 pm

## Re: fiddlin with repsit

Sun Mar 31, 2013 1:55 pm

Added function remove_unused_configs, changed the flow so that you always return to the main menu (in case you want to do more than one task). Only bug I can find (with limited testing) is that the query list doesn't get deleted before a second query, so if you repeat check_status, the list keeps growing. The list does get deleted by the time the script exits. See lines 608, 609.
https://gist.github.com/fsmithred/5280647
Post a reply
Jump to:

Powered by phpBB © phpBB Group.

phpBB Mobile / SEO by Artodia.