You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@subversion.apache.org by Jeremy Conlin <je...@gmail.com> on 2007/03/19 19:25:27 UTC

Help with ~/.subversion/config

I have set some configuration options in my ~/.subversion/config
file.  Specifically I want to ignore files with an extension of "pyc"
so in my config file I have

global-ignores = *.o *.lo *.la #*# .*.rej *.rej .*~ *~ .#* .DS_Store
*.pyc .*.sw* *.aux

Secondly, whenever I add a file with extension "py" or "tex" I want to
add some keywords.  So in my config file I have

*.py = svn:keywords="Author Date Revision Id email"
*.tex = svn:keywords="Author Date Revision Id email"

I have noticed that subversion is not always ignoring pyc files and it
isn't always automatically adding keywords to py and tex files.  I set
up my repository and my working copy before I modified my config
file.  Previously, I was setting these options by hand in each
directory.

Is there some reason why these options are not being seen/followed?
Thanks,
Jeremy

Re: Help with ~/.subversion/config

Posted by Kris Deugau <kd...@vianet.ca>.
Jeremy Conlin wrote:
> I have set some configuration options in my ~/.subversion/config
> file.  Specifically I want to ignore files with an extension of "pyc"
> so in my config file I have
> 
> global-ignores = *.o *.lo *.la #*# .*.rej *.rej .*~ *~ .#* .DS_Store
> *.pyc .*.sw* *.aux
> 
> Secondly, whenever I add a file with extension "py" or "tex" I want to
> add some keywords.  So in my config file I have
> 
> *.py = svn:keywords="Author Date Revision Id email"
> *.tex = svn:keywords="Author Date Revision Id email"
> 
> I have noticed that subversion is not always ignoring pyc files and it
> isn't always automatically adding keywords to py and tex files.

Actually, it's working as coded...   just not as you're expecting.

Remove the quotes and all of the keywords specified should get 
substituted.  (Side note:  is "email" actually a Subversion keyword?)

-kgd

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

Re: Help with ~/.subversion/config

Posted by Jeremy Conlin <je...@gmail.com>.
On 3/19/07, Ryan Schmidt <su...@ryandesign.com> wrote:
>
> On Mar 19, 2007, at 14:25, Jeremy Conlin wrote:
>
> > I have set some configuration options in my ~/.subversion/config
> > file.  Specifically I want to ignore files with an extension of "pyc"
> > so in my config file I have
> > global-ignores = *.o *.lo *.la #*# .*.rej *.rej .*~ *~ .#* .DS_Store
> > *.pyc .*.sw* *.aux
> >
> > Secondly, whenever I add a file with extension "py" or "tex" I want to
> > add some keywords.  So in my config file I have
> >
> > *.py = svn:keywords="Author Date Revision Id email"
> > *.tex = svn:keywords="Author Date Revision Id email"
> >
> > I have noticed that subversion is not always ignoring pyc files and it
> > isn't always automatically adding keywords to py and tex files.  I set
> > up my repository and my working copy before I modified my config
> > file.  Previously, I was setting these options by hand in each
> > directory.
> >
> > Is there some reason why these options are not being seen/followed?
>
> Subversion should be applying your svn:keywords to your *.py and
> *.tex files. However, the Author and email keywords will not work.
> And, there is no keyword called "email" so that's irrelevant. So it's
> just the Author keyword that won't work. You need to specify it
> without the quotes, like this:
>
> *.py = svn:keywords=Author Date Revision Id
> *.tex = svn:keywords=Author Date Revision Id
>
>
> Otherwise Subversion thinks the quotes are part of the keyword name,
> and then it can't find a keyword called: "Author
>
> You will of course also need the line
>
> enable-auto-props = yes


Apparantely, I hadn't read through the config file enough.  I had forgotten
to uncomment the above line.  It only makes sense that it's something as
simple as that.
Thanks for the help!
Jeremy

Re: Help with ~/.subversion/config

Posted by Ryan Schmidt <su...@ryandesign.com>.
On Mar 19, 2007, at 14:25, Jeremy Conlin wrote:

> I have set some configuration options in my ~/.subversion/config
> file.  Specifically I want to ignore files with an extension of "pyc"
> so in my config file I have
> global-ignores = *.o *.lo *.la #*# .*.rej *.rej .*~ *~ .#* .DS_Store
> *.pyc .*.sw* *.aux
>
> Secondly, whenever I add a file with extension "py" or "tex" I want to
> add some keywords.  So in my config file I have
>
> *.py = svn:keywords="Author Date Revision Id email"
> *.tex = svn:keywords="Author Date Revision Id email"
>
> I have noticed that subversion is not always ignoring pyc files and it
> isn't always automatically adding keywords to py and tex files.  I set
> up my repository and my working copy before I modified my config
> file.  Previously, I was setting these options by hand in each
> directory.
>
> Is there some reason why these options are not being seen/followed?

Subversion should be applying your svn:keywords to your *.py and  
*.tex files. However, the Author and email keywords will not work.  
And, there is no keyword called "email" so that's irrelevant. So it's  
just the Author keyword that won't work. You need to specify it  
without the quotes, like this:

*.py = svn:keywords=Author Date Revision Id
*.tex = svn:keywords=Author Date Revision Id


Otherwise Subversion thinks the quotes are part of the keyword name,  
and then it can't find a keyword called: "Author

You will of course also need the line

enable-auto-props = yes

in your config file. I assume you have that already. Also, the auto- 
props will only apply to new files you add to the repo, not any  
existing files in the repo. (If you need the latter, there is a  
script you can use.)


As to the ignore rules, they should work too, but if the to-be- 
ignored files are already in the repo, they will stay there; they  
will not be ignored. Also, if you do something like "svn add *" and  
there are to-be-ignored files in the directory, Subversion will not  
ignore them, because by saying "*" you have explicitly asked for all  
files to be added, and Subversion does so.


If the above does not help, try showing us a set of commands you  
issue (and their output) that demonstrate the problem you're seeing.



-- 

To reply to the mailing list, please use your mailer's Reply To All  
function


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