You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@subversion.apache.org by Olivier Sannier <ob...@free.fr> on 2006/11/11 12:31:03 UTC

Getting the diffs as whole files

Hi,

Is there a way to get the diffs from a branch to the trunk as whole files?
I can get one file with all the diffs, but what I want is the set of all 
files that have been modified, files containing the said modifications.

Is there a special way to call svn diff to do that? I tried looking in 
svn book but did not manage to find anything related to this.

Thanks for any help
Olivier

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org

Re: Getting the diffs as whole files

Posted by Tim Hill <dr...@comcast.net>.
I think the solution was already mentioned. There isn't a single  
command, but you can use svn diff --summarize to get the list of  
files, then feed that list one file at a time into svn cat to get the  
actual contents. Should be pretty simple?

--Tim

On Nov 14, 2006, at 2:59 PM, Olivier Sannier wrote:

> Olivier Sannier wrote:
>> Andy Levy wrote:
>>> On 11/11/06, Olivier Sannier <ob...@free.fr> wrote:
>>>> Hi,
>>>>
>>>> Is there a way to get the diffs from a branch to the trunk as  
>>>> whole files?
>>>> I can get one file with all the diffs, but what I want is the  
>>>> set of all
>>>> files that have been modified, files containing the said  
>>>> modifications.
>>>>
>>>> Is there a special way to call svn diff to do that? I tried  
>>>> looking in
>>>> svn book but did not manage to find anything related to this.
>>>
>>> You mean just get a listing of all the files that changed? Check out
>>> svn diff --summarize, new in SVN 1.4.
>> No, I mean the complete content of files that have changed from  
>> the branch to the trunk (or a revision to another).
>> Basically, the content of the files listed by summarize.
>
> Anyone?
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
> For additional commands, e-mail: users-help@subversion.tigris.org
>

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org

Re: Getting the diffs as whole files

Posted by Olivier Sannier <ob...@free.fr>.
Olivier Sannier wrote:
> Andy Levy wrote:
>> On 11/11/06, Olivier Sannier <ob...@free.fr> wrote:
>>> Hi,
>>>
>>> Is there a way to get the diffs from a branch to the trunk as whole 
>>> files?
>>> I can get one file with all the diffs, but what I want is the set of 
>>> all
>>> files that have been modified, files containing the said modifications.
>>>
>>> Is there a special way to call svn diff to do that? I tried looking in
>>> svn book but did not manage to find anything related to this.
>>
>> You mean just get a listing of all the files that changed? Check out
>> svn diff --summarize, new in SVN 1.4.
> No, I mean the complete content of files that have changed from the 
> branch to the trunk (or a revision to another).
> Basically, the content of the files listed by summarize.

Anyone?

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org

Re: Getting the diffs as whole files

Posted by Bob Proulx <bo...@proulx.com>.
Olivier Sannier wrote:
> No, I mean the complete content of files that have changed from the 
> branch to the trunk (or a revision to another).
> Basically, the content of the files listed by summarize.

After you get a listing of the files that have changed use that to
'cat' the file contents.

  svn cat somefile

And the one-liner to do it all at one time.

  for f in $(svn st | awk '$1=="M"{print$NF}');do svn cat $f ; done

Bob

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org

Re: Getting the diffs as whole files

Posted by Olivier Sannier <ob...@free.fr>.
Andy Levy wrote:
> On 11/11/06, Olivier Sannier <ob...@free.fr> wrote:
>> Hi,
>>
>> Is there a way to get the diffs from a branch to the trunk as whole 
>> files?
>> I can get one file with all the diffs, but what I want is the set of all
>> files that have been modified, files containing the said modifications.
>>
>> Is there a special way to call svn diff to do that? I tried looking in
>> svn book but did not manage to find anything related to this.
>
> You mean just get a listing of all the files that changed? Check out
> svn diff --summarize, new in SVN 1.4.
No, I mean the complete content of files that have changed from the 
branch to the trunk (or a revision to another).
Basically, the content of the files listed by summarize.

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org

Re: Finding files based on keyword or tag

Posted by Talden <ta...@gmail.com>.
On 14/11/06, Mohammed Rahman <mr...@yahoo.com> wrote:
> All,
> If you are coming from CVS world you all know that in CVS you could find
> files or search for files in a project based on Tag, for example if I have
> following file structure
>
> Project AZ
>     Directory A
>        - File b
>        - File c
>        - File d
>        - Directory B
>              - File e
>              - File c
>              - File h
>
> .....etc.
>
> And in this structure after I finish code review, I could tag any specific
> file as "Approved" or any other meaningful name so that later I could find
> that file and make a build. So in the above directory structure, I could tag
> File c as Approved and leave rest of the files untagged. In subversion I am
> looking for similar feature, since CVS tag concept is gone in subversion and
> has been replaced with copy concept, I am just wondering if anyone knows how
> to achieve CVS's tag concept in subversion without using svn copy. I thought
> I could use subversion's keyword feature but I can add keyword in a file but
> later I can not find that file based on the keyword. Please help.

I have to agree, for all the arguments for the existing tags and
branches as copies, there are casualties.  The ability to tag a set of
files not residing in the same folder yet retaining their relative
context is non-trivial.

Also notable is the lack of support in the client for finding
files/folders with matching attributes (be they name, property,
property value or a change between, before, on or after a given
time-stamp).

Tagging the way you're suggesting isn't conveniently supported (unless
I'm missing something from my own investigations).

--
Talden

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org

Finding files based on keyword or tag

Posted by Mohammed Rahman <mr...@yahoo.com>.
All,
If you are coming from CVS world you all know that in CVS you could find files or search for files in a project based on Tag, for example if I have following file structure

Project AZ
    Directory A
       - File b
        - File c
        - File d
        - Directory B
               - File e
               - File c
               - File h

.....etc.

And in this structure after I finish code review, I could tag any specific file as "Approved" or any other meaningful name so that later I could find that file and make a build. So in the above directory structure, I could tag File c as Approved and leave rest of the files untagged. In subversion I am looking for similar feature, since CVS tag concept is gone in subversion and has been replaced with copy concept, I am just wondering if anyone knows how to achieve CVS's tag concept in subversion without using svn copy. I thought I could use subversion's keyword feature but I can add keyword in a file but later I can not find that file based on the keyword. Please help.






"I have nothing new to teach the world. Truth and non-violence are as old as the hills." ------Mahatma Gandhi

Re: Getting the diffs as whole files

Posted by Andy Levy <an...@gmail.com>.
On 11/11/06, Olivier Sannier <ob...@free.fr> wrote:
> Hi,
>
> Is there a way to get the diffs from a branch to the trunk as whole files?
> I can get one file with all the diffs, but what I want is the set of all
> files that have been modified, files containing the said modifications.
>
> Is there a special way to call svn diff to do that? I tried looking in
> svn book but did not manage to find anything related to this.

You mean just get a listing of all the files that changed? Check out
svn diff --summarize, new in SVN 1.4.

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org