Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 44526 - sync ebuilds of installed packages only
Summary: sync ebuilds of installed packages only
Status: RESOLVED DUPLICATE of bug 45221
Alias: None
Product: Portage Development
Classification: Unclassified
Component: Conceptual/Abstract Ideas (show other bugs)
Hardware: All All
: High enhancement (vote)
Assignee: Portage team
URL:
Whiteboard:
Keywords:
: 58571 66823 (view as bug list)
Depends on:
Blocks:
 
Reported: 2004-03-12 19:22 UTC by Tim Cera
Modified: 2005-07-17 13:06 UTC (History)
4 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
Diff of patched emerge to only sync ebuilds of installed packages (emerge.diff,1.67 KB, patch)
2004-03-12 19:27 UTC, Tim Cera
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Tim Cera 2004-03-12 19:22:11 UTC
The only ebuilds that I _need_ to know about updates for are the ones that I have 
installed.  But, I still carry around the entire portage tree.

Syncing only the ebuilds of the installed packages has several benefits:
1) Less stress on the rsync servers.
2) Faster syncronization.
3) Scalable - in fact it won't really matter how big the portage tree gets.
...and the best part...
4) The rsync server logs could be used to establish installation statistics. 

Problems:
1) Actually syncing only installed ebuilds -> Done, see attached diff against 
'/usr/bin/emerge' as of 3/12/2004.
2) 'emerge -s' would need to search http://packages.gentoo.org instead of 
searching the local version of the portage tree.
3) New dependencies would have to be added to the list of synced ebuilds.

Diff file of my addition of the '--syncinstalled' option is attached.  Usage is 
'emerge --syncinstalled sync'.  The reference emerge is version 1.264 in the 
CVS header, current as of 3/12/2004.  I actually create a file in /tmp which 
is a horrible kludge, I just couldn't figure out how to pipe the list to stdin of 
rsync - so there is room for improvement.  Has worked well for me over the 
past couple of weeks.  Once a change in the dependencies brought up an 
error so I just did a full sync and it went away (see #3 in the problems 
section).
Comment 1 Tim Cera 2004-03-12 19:27:16 UTC
Created attachment 27271 [details, diff]
Diff of patched emerge to only sync ebuilds of installed packages

Diff against emerge CVS version 1.264, portage-2.0.50-r1, on 3/12/2004.
Comment 2 Nicholas Jones (RETIRED) gentoo-dev 2004-03-13 13:17:08 UTC
What about changing dependencies? If you alter your use flags you
may pull in a new dependency... which will probably break after a
short while with this method. The only "perfect" way to resolve
this issue would be a complete dep resolver and get each package.

The idea is good, but there are side effect to it. Minimally it
needs a warning that it isn't always going to work as expected.
Comment 3 Tim Cera 2004-03-14 18:48:06 UTC
Nicholas, thanks for your comments.  My patch is not even close to a complete solution and you 
are correct that there is a problem if the dependencies change.  A finished implementation would 
catch changed dependencies and add the new ebuild(s) to the sync list and sync the new ebuild.
Comment 4 Brian Harring (RETIRED) gentoo-dev 2005-02-28 00:15:56 UTC
Foreward duping this on 45221, since the concept there is a bit saner (this approach would require multiple rounds of sync's to get all deps.  This would suck.)

*** This bug has been marked as a duplicate of 45221 ***
Comment 5 Brian Harring (RETIRED) gentoo-dev 2005-02-28 01:22:05 UTC
*** Bug 58571 has been marked as a duplicate of this bug. ***
Comment 6 Brian Harring (RETIRED) gentoo-dev 2005-02-28 01:22:44 UTC
*** Bug 66823 has been marked as a duplicate of this bug. ***