Brian Harring wrote:

>>>[snip]
>>>      
>>>
>>Why you could not use ctime/mtime ? Isn't possible to make a check like
>>you do now but only on a filtered by "mtime" list of ebuild ?
>>A command like this
>># find . -name "*.ebuild" -and -mtime "-7" -or -ctime "-7"
>>    
>>
>Actually... nope. :)
>You're forgetting about eclass changes, which can adjust metadata 
>(deps) of an ebuild w/out the ebuild ever being modified...
>~brian
>  
>
right was forgotting that :P , what about something like this ?

HAS_MODIFIED_ECLASS=$( find /usr/portage/eclass/ -name "*.eclass" -and
-ctime "-1" -mtime "-1" )
if [[ -z  $HAS_MODIFIED_ECLASS ]] ; then
  echo "Good, using faster method"   
  find /usr/portage -name "*.ebuild" \
  -and -mtime "-1" \
  -or -ctime "-1" \
  -exec something_here.sh
else
  find /usr/portage -name "*.ebuild" \
  -exec something_here.sh
fi

will save you often, eclasses are not so frequently updated ;-)
-- 
[email protected] mailing list

Reply via email to