Go to:
Gentoo Home
Documentation
Forums
Lists
Bugs
Planet
Store
Wiki
Get Gentoo!
Gentoo's Bugzilla – Attachment 19028 Details for
Bug 28128
integrate emerge-webrsync functionality in emerge sync
Home
|
New
–
[Ex]
|
Browse
|
Search
|
Privacy Policy
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
patch to make emerge --sync recognize SYNC="http://" urls
websync.patch (text/plain), 1.60 KB, created by
Marius Mauch (RETIRED)
on 2003-10-09 12:54:33 UTC
(
hide
)
Description:
patch to make emerge --sync recognize SYNC="http://" urls
Filename:
MIME Type:
Creator:
Marius Mauch (RETIRED)
Created:
2003-10-09 12:54:33 UTC
Size:
1.60 KB
patch
obsolete
>--- bin/emerge.org 2003-09-30 05:29:17.000000000 +0200 >+++ bin/emerge 2003-09-30 20:36:53.000000000 +0200 >@@ -1835,7 +1835,34 @@ > mycommand=mycommand+" --exclude-from "+portage.settings["RSYNC_EXCLUDEFROM"] > else: > print "!!! RSYNC_EXCLUDEFROM specified, but file does not exist." >- mycommand=mycommand+" "+mysyncuri+"/* "+myportdir >+ >+ # this is a rewrite of the old emerge-webrsync code >+ if mysyncuri[:7] == "http://" or mysyncuri[:6] == "ftp://": >+ attempts = 0 >+ downloaded = False >+ minsize=1024*1024 >+ while attempts < 40 and not downloaded: >+ mytime = time.localtime() - (attempts*24*60*60) >+ mysnapshot = time.strftime("%d%m%Y", mytime)+".tar.bz2" >+ syncdir=portage.settings["PORTAGE_TMPDIR"]+"/websync" >+ for m in mysyncuri.split(): >+ if not os.path.exists(syncdir): >+ os.mkdir(syncdir) >+ os.chdir(syncdir) >+ myfetchcmd=portage.settings["FETCH_COMMAND"]+" "+m+"/snapshots/"+mysnapshot >+ print yellow("*"), "trying to download snapshot "+mysnapshot+" from "+m >+ if portage.spawn(mycmd, free=1) == 0: >+ if os.path.exists(mysnapshot) and os.lstat(mysnapshot)[6] > minsize: >+ print green("*"), mysnapshot+" successfully downloaded" >+ downloaded = True >+ attempts += 1 >+ if not downloaded: >+ print red("*"), "could not download a complete snapshot" >+ sys.exit(1) >+ portage.spawn("tar xjf "+mysnapshot, free=1) >+ mycommand=mycommand+" "+syncdir+"/portage/* "+myportdir >+ else: >+ mycommand=mycommand+" "+mysyncuri+"/* "+myportdir > print ">>> starting rsync with "+mysyncuri+"..." > exitcode=portage.spawn(mycommand,free=1) > #exitcode=0
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 28128
:
19028
|
19737
|
19939