Discussion:
[9fans] fun with replica and pull
(too old to reply)
John Floren
2011-12-20 06:00:18 UTC
Permalink
I'd like to install Erik's nupas, but according to contrib/install, a
bunch of files have been modified locally, so it doesn't install them.
Then, if I try to do a contrib/pull, it believes the package is up to
date. Ok, great, so I do "replica/pull -v /dist/replica/nupas", which
still complains that a ton of files are locally modified. As far as I
can tell, you must specify each individual file in a -s switch to
replica before it'll actually do the right thing--yuck. Is there any
way for me to just install the thing and damn the consequences? I've
looked at the list of files it's afraid to overwrite, they're not
anything I made modifications to (or at least, no important
modifications).


John
Peter A. Cejchan
2011-12-20 08:48:17 UTC
Permalink
I experienced the same when pulling system files after some time of not
upgrading. Also, I am pretty sure that I have not modified those files
listed as modified locally. I tried pull -s *, but it did not work at all.

Thanks,
Peter.
Peter A. Cejchan
2011-12-20 09:21:20 UTC
Permalink
yes, I expected that. thanks! Peter

On Tue, Dec 20, 2011 at 10:17 AM, Steve Simon <***@quintile.net> wrote:
...
Steve Simon
2011-12-20 09:17:23 UTC
Permalink
Post by Peter A. Cejchan
pull -s *
This will not work. You need to pull each file that is marked
as modified, prefixed by the -s option to take the server (the labs)
version or -c to keep the version you have locally (and silence
the error).

It is the work of moments to load the debug printed by pull -v
into favorite plan9 editor, and modify it into a command line
to fetch the modified files.

-Steve
erik quanstrom
2011-12-20 13:23:27 UTC
Permalink
Post by John Floren
I'd like to install Erik's nupas, but according to contrib/install, a
bunch of files have been modified locally, so it doesn't install them.
Then, if I try to do a contrib/pull, it believes the package is up to
date. Ok, great, so I do "replica/pull -v /dist/replica/nupas", which
still complains that a ton of files are locally modified. As far as I
can tell, you must specify each individual file in a -s switch to
replica before it'll actually do the right thing--yuck. Is there any
way for me to just install the thing and damn the consequences? I've
looked at the list of files it's afraid to overwrite, they're not
anything I made modifications to (or at least, no important
modifications).
if you're feeling like a really big hammer, why not run pull
once, run through sed/awk/whatever to generate a complete
list of -s'es and run pull again?

disgusting, no?

- erik
ron minnich
2011-12-20 15:57:00 UTC
Permalink
Post by erik quanstrom
if you're feeling like a really big hammer, why not run pull
once, run through sed/awk/whatever to generate a complete
list of -s'es and run pull again?
disgusting, no?
it reminds me of why we went with hg on the NIX tree.

ron
Federico Benavento
2011-12-20 16:09:55 UTC
Permalink
Post by ron minnich
it reminds me of why we went with hg on the NIX tree.
because at the time you did it things like bitbucket and the hg port came to exist?

so what one should do, use replica to sync with sources and move the all the contribs
to bitbucket google code?
Jens Staal
2011-12-20 16:24:30 UTC
Permalink
Post by Federico Benavento
Post by ron minnich
it reminds me of why we went with hg on the NIX tree.
because at the time you did it things like bitbucket and the hg port came to exist?
so what one should do, use replica to sync with sources and move the all the contribs
to bitbucket google code?
That sounds like a pretty good idea :)

I played with a similar idea with the
http://code.google.com/p/ports2plan9/

I am however still a beginner (I hope to improve my Plan9 skills and
learn as I go along with various (increasingly advanced) porting efforts
without actually having an "agenda" or aim as such), but if people want
to upload their contribs to that repository they are free to do so.

By the way - is someone working on an update of the Python2 port? and
what about the hg-git plugin? Just wondering if I should start playing
with those or leave that to someone else.
Yaroslav
2011-12-20 15:47:39 UTC
Permalink
Replica(8) is bad at overlaying several sources...
Perhaps contrib(1) should hide this somehow.
Peter A. Cejchan
2011-12-21 08:17:22 UTC
Permalink
No, not disgusting... I gonna do that, inspect the list, and do a pull. I
think I have cfg files backupped (at least, n-1 ;-)
Post by erik quanstrom
...
list of -s'es and run pull again?
Post by erik quanstrom
disgusting, no?
John Floren
2011-12-21 00:15:11 UTC
Permalink
Post by John Floren
I'd like to install Erik's nupas, but according to contrib/install, a
bunch of files have been modified locally, so it doesn't install them.
Then, if I try to do a contrib/pull, it believes the package is up to
date. Ok, great, so I do "replica/pull -v /dist/replica/nupas", which
still complains that a ton of files are locally modified. As far as I
can tell, you must specify each individual file in a -s switch to
replica before it'll actually do the right thing--yuck. Is there any
way for me to just install the thing and damn the consequences? I've
looked at the list of files it's afraid to overwrite, they're not
anything I made modifications to (or at least, no important
modifications).
John
I ended up writing "decontrib", which will download all the files from
a contrib package into a local directory and make a tarball for you.
Then you can do whatever you like.

Thus:

% decontrib quanstro nupas
[lots of output removed]
% ls | grep nupas
nupas
nupas.tgz
% lc nupas
386 README acme mail rc sys
%

It's in /n/sources/contrib/john/decontrib
Continue reading on narkive:
Loading...