Is it possible to pull changed files if the code sever hasn't commit/update it?

View: New views
5 Messages — Rating Filter:   Alert me  

Is it possible to pull changed files if the code sever hasn't commit/update it?

by Cloud Strife-2 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hi everyone.
Assuming the following condition:
I have a code server A, a compilatioin-test machine B. Then I modify some files in server A. Just at this point, I run "hg pull" to get the modified files in A, then fail. hg reports nothing updated.
Then here comes my question: how can I "sync" the server and the client, assuming I am not allowed to run "hg commit/hg update"? is it possible to do so?
 
Thank you very much for any answer or hit.
Best regards.
 
2009-10-31

Alex.Wang

_______________________________________________
Mercurial mailing list
Mercurial@...
http://selenic.com/mailman/listinfo/mercurial

Re: Is it possible to pull changed files if the code server hasn't commit/update it?

by Martin Geisler-4 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

"Alex.Wang" <geforce8800@...> writes:

> Hi everyone.
> Assuming the following condition:
>
> I have a code server A, a compilatioin-test machine B. Then I modify
> some files in server A. Just at this point, I run "hg pull" to get the
> modified files in A, then fail. hg reports nothing updated.
> Then here comes my question: how can I "sync" the server and the
> client, assuming I am not allowed to run "hg commit/hg update"? is it
> possible to do so?

You cannot. Mercurial only moves *history* (changesets) from one
repository to another, and until you have made a commit, the changes are
not part of the history.

You'll have to use some other transport mechanism such as scp.

--
Martin Geisler

VIFF (Virtual Ideal Functionality Framework) brings easy and efficient
SMPC (Secure Multiparty Computation) to Python. See: http://viff.dk/.


_______________________________________________
Mercurial mailing list
Mercurial@...
http://selenic.com/mailman/listinfo/mercurial

attachment0 (203 bytes) Download Attachment

Re: Is it possible to pull changed files if the code server hasn't commit/update it?

by Paul Franz-4 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Since the changes have not been committed, you should be able to use "hg
diff" to generate a patch that can be transfered to the client and
applied there and then the changes in the server A workspace can be
dropped via an "hg revert -a"

Paul Franz

Martin Geisler wrote:

> "Alex.Wang" <geforce8800@...> writes:
>
>  
>> Hi everyone.
>> Assuming the following condition:
>>
>> I have a code server A, a compilatioin-test machine B. Then I modify
>> some files in server A. Just at this point, I run "hg pull" to get the
>> modified files in A, then fail. hg reports nothing updated.
>> Then here comes my question: how can I "sync" the server and the
>> client, assuming I am not allowed to run "hg commit/hg update"? is it
>> possible to do so?
>>    
>
> You cannot. Mercurial only moves *history* (changesets) from one
> repository to another, and until you have made a commit, the changes are
> not part of the history.
>
> You'll have to use some other transport mechanism such as scp.
>
>  
> ------------------------------------------------------------------------
>
> _______________________________________________
> Mercurial mailing list
> Mercurial@...
> http://selenic.com/mailman/listinfo/mercurial
>  
_______________________________________________
Mercurial mailing list
Mercurial@...
http://selenic.com/mailman/listinfo/mercurial

Parent Message unknown Re: Is it possible to pull changed files if the code server hasn'tcommit/update it?

by Paul Franz-4 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Is version B and C modifying the same files? And often is this
occurring? How is the below example related to the problem with server A
and not being able to commit on the server A box?

Paul Franz

Alex.Wang wrote:

> Thank you very much for your advisition.
> I have tried your idea. However, there is another problem by using patch.
> Please conside the following conditions:
> I have an original version A, then it has two branches by two person.
> Assuming they have version B and C, obviously when B is changed, there
> is a patch delta(B) which can be only applied to B. C is the same.
> So if I get a delta(C), it always confilcts with version B. It is
> especially annoying to need manual interference when the conflicting
> sets are rather HUGE.
> Would you please give me some hits or techniques about how to deal
> with such conditions?
> Best regards.
> 2009-11-01
> ------------------------------------------------------------------------
> Alex.Wang
> ------------------------------------------------------------------------
> *发件人:* Paul Franz
> *发送时间:* 2009-11-01 08:16:21
> *收件人:* Martin Geisler
> *抄送:* mercurial
> *主题:* Re: Is it possible to pull changed files if the code server
> hasn'tcommit/update it?
> Since the changes have not been committed, you should be able to use "hg
> diff" to generate a patch that can be transfered to the client and
> applied there and then the changes in the server A workspace can be
> dropped via an "hg revert -a"
> Paul Franz
> Martin Geisler wrote:
> > "Alex.Wang" <geforce8800@...> writes:
> >
> >
> >> Hi everyone.
> >> Assuming the following condition:
> >>
> >> I have a code server A, a compilatioin-test machine B. Then I modify
> >> some files in server A. Just at this point, I run "hg pull" to get the
> >> modified files in A, then fail. hg reports nothing updated.
> >> Then here comes my question: how can I "sync" the server and the
> >> client, assuming I am not allowed to run "hg commit/hg update"? is it
> >> possible to do so?
> >>
> >
> > You cannot. Mercurial only moves *history* (changesets) from one
> > repository to another, and until you have made a commit, the changes are
> > not part of the history.
> >
> > You'll have to use some other transport mechanism such as scp.
> >
> >
> > ------------------------------------------------------------------------
> >
> > _______________________________________________
> > Mercurial mailing list
> > Mercurial@...
> > http://selenic.com/mailman/listinfo/mercurial
> >
> _______________________________________________
> Mercurial mailing list
> Mercurial@...
> http://selenic.com/mailman/listinfo/mercurial
_______________________________________________
Mercurial mailing list
Mercurial@...
http://selenic.com/mailman/listinfo/mercurial

Parent Message unknown Re: Is it possible to pull changed files if the code server hasn'tcommit/update it?

by Martin Geisler-4 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

"Alex.Wang" <geforce8800@...> writes:

> Thank you very much for your answer.

You're welcome -- I'm sending my answer back to the mailinglist.

> Then are you willing to share with me if there are some tools that can
> do this? I mean I always edit source files everywhere, then do you
> know whether there is a method to put all "changed" files together and
> transfer them to remote host to update old files?

Well, you can of course commit on all the machines and then pull the
changesets from one machine to another and then finally push them to
your server.

> It is really a little annoying I should commit changes with a message
> even the change is so tiny that it isn't worthy doing so at all.

Oh, but there are no changes that are unworthy of a commit! :-) I made
this commit a couple of days ago:

  http://hg.intevation.org/mercurial/crew/rev/563a9c3a7d2e

Notice how the commit message is 194 times as long as the change :-D

> Thank you for any further guidance.
> Best luck.
>
>
> 2009-10-31
>
>
>
> Alex.Wang

--
Martin Geisler

VIFF (Virtual Ideal Functionality Framework) brings easy and efficient
SMPC (Secure Multiparty Computation) to Python. See: http://viff.dk/.
_______________________________________________
Mercurial mailing list
Mercurial@...
http://selenic.com/mailman/listinfo/mercurial