View previous topic :: View next topic |
Author |
Message |
hitman200ca Tux's lil' helper
Joined: 02 Oct 2002 Posts: 110 Location: Canada
|
Posted: Wed Jun 09, 2004 6:16 pm Post subject: |
|
|
Slightly different than above.
A useful root script to have lying around.
checkuse.sh - finds all packages that have outdates use flags
or all packages the have a specific outdated use flag (as given
on command line)
Code: | #!/bin/sh
for foo in `qpkg -I -nc -v`
do
if etcat -u =$foo | grep -iq " + - $1\| - + $1"; then
etcat -u =$foo
fi
done
|
Prints out all of the etcat's when no command line arg is given
and if you provide the use flag you are looking for it will show
only those
Code: | StormCloud root # ./checkuse.sh kde
[ Colour Code : set unset ]
[ Legend : (U) Col 1 - Current USE flags ]
[ : (I) Col 2 - Installed With USE flags ]
U I [ Found these USE variables in : dev-java/sun-jdk-1.4.2.04 ]
- - doc : Adds extra documentation (API, Javadoc, etc)
+ + gnome : Adds GNOME support
- + kde : Adds support for kde-base/kde (K Desktop Enviroment)
+ + mozilla : Adds mozilla support
|
_________________ "Against stupidity, the Gods themselves contend in vain."
-- Friedrich von Schiller |
|
Back to top |
|
|
PiotrBanasik n00b
Joined: 26 Aug 2004 Posts: 8 Location: Burnaby, BC
|
Posted: Wed Sep 01, 2004 5:51 pm Post subject: |
|
|
Here is a script I ended up making for my purposes that does this ...
Code: | #!/bin/sh
MATCH=;
echo -n "Calculating Dependancies ";
for a in $(qpkg -I -nc); do
equery -C uses $a | grep -q -e '^ - +' -e '^ + -' && {
echo -n "+";
MATCH="${MATCH} $a";
} || {
echo -n ".";
};
done;
emerge -va ${MATCH}; |
any feedback is welcome |
|
Back to top |
|
|
Gatak Apprentice
Joined: 04 Jan 2004 Posts: 174
|
Posted: Thu Sep 02, 2004 8:44 am Post subject: |
|
|
Nice script. It would be nice if it printed the current package it was equerying. Code: | #!/bin/sh
MATCH=;
echo "Calculating Dependancies ";
for a in $(qpkg -I -nc); do
equery -C uses $a | grep -q -e '^ - +' -e '^ + -' && {
echo $a " +";
MATCH="${MATCH} $a";
} || {
echo $a;
};
done;
emerge -va ${MATCH}; |
Last edited by Gatak on Thu Sep 02, 2004 9:15 am; edited 2 times in total |
|
Back to top |
|
|
rinnan Tux's lil' helper
Joined: 24 May 2003 Posts: 138 Location: Honolulu, Hawai`i
|
Posted: Thu Sep 02, 2004 9:07 am Post subject: eflagsync |
|
|
Wrote this a while ago... called it "eflagsync"... put this into a file called "eflagsync" and make it executable... then just run it. It will produce a pretty report of just what packages have had flags change on them since they were installed and what those new flags are.
Code: | #!/bin/bash
for a in `qpkg -I -nc` ; do etcat uses $a ; done | egrep "\-\ \+"\|"\+\ \-"\|"Found" | egrep --before-context=1 "\-\ \+"\|"\+\ \-" |
|
|
Back to top |
|
|
kallamej Administrator
Joined: 27 Jun 2003 Posts: 4975 Location: Gothenburg, Sweden
|
|
Back to top |
|
|
|