From: Brian Harring <ferringb@gentoo.org>
To: gentoo-dev@lists.gentoo.org
Subject: Re: [gentoo-dev] why do different ebuilds have the same version number?
Date: Wed, 27 Apr 2005 15:25:48 -0500 [thread overview]
Message-ID: <20050427202548.GP29554@exodus.wit.org> (raw)
In-Reply-To: <426FEFD3.3080204@pnpitalia.it>
[-- Attachment #1: Type: text/plain, Size: 1703 bytes --]
On Wed, Apr 27, 2005 at 10:02:27PM +0200, Francesco Riosa wrote:
> 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 ;-)
Actually... :)
bit easier, abusing portage's own functionality.
python -c $'
import portage, time
target=long(time.strftime("%s",time.gmtime())) - 24*60*60
pdb=portage.portdb
for cp in pdb.cp_all():
for cpv in pdb.cp_list(cp):
flagged=False
try: mtime, eclasses = pdb.aux_get(cpv,["_mtime_","INHERITED"])
except SystemExit: raise
except: continue
if mtime >= target: flagged=True
else:
try:
for e in eclasses.split():
if pdb.eclassdb.eclasses[e][1] >= target:
flagged=True
break
except KeyError: flagged=True
if flagged: print cpv
'
~brian
[-- Attachment #2: Type: application/pgp-signature, Size: 189 bytes --]
next prev parent reply other threads:[~2005-04-27 20:25 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-04-27 13:09 [gentoo-dev] why do different ebuilds have the same version number? Imran Sher Rafique
2005-04-27 13:05 ` Caleb Tennis
2005-04-27 13:06 ` Mike Frysinger
2005-04-27 13:56 ` [gentoo-dev] " Imran Sher Rafique
2005-04-27 17:53 ` [gentoo-dev] " marduk
2005-04-27 19:07 ` Brian Harring
2005-04-27 19:17 ` Francesco Riosa
2005-04-27 19:41 ` Brian Harring
2005-04-27 20:02 ` Francesco Riosa
2005-04-27 20:25 ` Brian Harring [this message]
-- strict thread matches above, loose matches on Subject: below --
2005-04-27 20:36 Brian Harring
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20050427202548.GP29554@exodus.wit.org \
--to=ferringb@gentoo.org \
--cc=gentoo-dev@lists.gentoo.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox