You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@subversion.apache.org by Casper Hornstrup <ch...@users.sourceforge.net> on 2004/01/10 14:36:04 UTC
Default eol styles
Even though Subversion's svn:eol-style property makes it easier to
control eol styles than CVS, it can still be pretty difficult to do.
I have my code checked out onto a Windows machine, I'm using the
TortoiseSVN client on that machine and I do my editing using a
Windows IDE, but since I'm developing some partly unix-centric
software, I build it on a linux machine. Some files (like shell
scripts) need to have svn:eol-style=LF in order for them to be run
on linux. Now, for files added during normal development this may
be a small problem, but when doing vendor imports it is really a
pain to set the svn:eol-style property on the needed files. I would
prefer a server-side solution or a solution where the logic is
completely hidden in the Subversion client-side libraries since I
don't want to restict developers to be using a particular kind of
client. I have the following idea for a solution and would like
your opinion on it.
A new svn:eol-default (I'm not sure if the policy is to use plural
here, eg. "svn:eol-defaults") property that kan only be applied to
directories is created. It's value is a list of pattens (like for
the svn:ignore property) and eol styles. Eg.
<pattern>: <eol-style>
<pattern>: <eol-style>
...
<pattern> can for instance be configure, or *.sh.
<eol-style> can be native, CRLF, LF, or CR like for the svn:eol-style
property, but also none, so it can cancel an inherited (see below)
svn:eol-default.
Patterns that are located closer to the top of the list have higher
priority than patterns closer to the bottom of the list. When a
filename is matched by a pattern the processing of the value list of
the svn:eol-default property stops. Eg. the following list:
*: native
*.sh: none
will result in the default eol style for all new files being native
(even for files with filenames that matches the pattern *.sh). If you
wanted to make the default eol style native for all new files except
files with filenames matching the pattern *.sh, and make the default
eol style none for files with filenames matching the pattern *.sh
then change the order of the list to:
*.sh: none
*: native
The svn:eol-default property can be inherited. When it is to be
decided what the default eol style for files in a specific directory
should be, first a combined list of patterns and eol styles is
created. The combined list is created from the values of the
svn:eol-default properties in all parent directories of the file all
the way to the repository root. svn:eol-default properties of
directories that are located lower in the directory hierarchy have
higher priority than svn:eol-default properties of directories that
are located higher in the directory hierarchy. The value of a
lower-level svn:eol-default property is located before the value of a
higher-level svn:eol-default property in the combined list. To find
the default eol style, the combined list is scanned from top to
bottom, searching for a pattern that will match the filename of the
file that is to be added to the repository. If the filename matches
a pattern, then the default eol style is determined by this entry. If
no pattern that matches the filename is found, then the default eol
style is none. The following is an example of use:
/repos (A)
/repos/vendor (B)
/repos/vendor/project1 (C)
/repos/vendor/project1/current (D)
svn:eol-default property values:
(A)
*: native
(B)
configure: LF
*.sh: LF
(C)
*.sh: none
(D) (has no svn:eol-default property)
A: All new files in this repository default to having the
svn:eol-style with value native (unless overridden by a
svn:eol-default property on a subdirectory).
B: New files that are added below the vendor directory that are named
configure or have a .sh extension default to having the
svn:eol-style with value LF.
C: Inherited from B and A we have the list (configure: LF),
(*.sh: LF), (*: native). Now we add (*.sh: none) from C to the top
of the list and we get the complete list: (*.sh: none),
(configure: LF), (*.sh: LF), (*: native). So new files that are
added below the vendor/project1 directory with filenames matching
the pattern *.sh has no default eol style. Files named configure
default to having svn:eol-style with value LF. All other files
default to having svn:eol-style with value native.
D: The rules for default eol style are the same as for C.
When the user adds a file to a directory using svn add or svn import,
the svn:eol-style property is set according to the svn:eol-default
properties of the parent directories (unless it is a binary file). Of
course, if the user explicitly sets the svn:eol-style on a file, then
it will override the default eol style set for the directory in which
the file is added.
Casper Hornstrup
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Re: Default eol styles
Posted by Casper Hornstrup <ch...@users.sourceforge.net>.
> -----Oprindelig meddelelse-----
> Fra: Erik Huelsmann [mailto:e.huelsmann@gmx.net]
> Sendt: 11. januar 2004 16:13
> Til: Casper Hornstrup
> Cc: users@subversion.tigris.org
> Emne: Re: Default eol styles
>
>
> > How can I set a default svn:eol-style for new files and still have
> > rules for other files?
>
> I don't understand this question. Auto-props are used to set
> properties on files. Which means that if you change the
> auto-props settings only newly added files will be affected.
> All files which are already added have their properties set
> and thus continue to use whatever rules were set when they
> were added... If you want to change those rules, you can
> change the properties of those files in the repository.
>
> bye,
>
> Erik.
Say, I svn import a package at version 1.0 and want all files to have
svn:eol-style=native, except some files matching some patterns (say
files named configure for this example) which should have
svn:eol-style=LF.
Now, I can use auto-props to set svn:eol-style=native for all imported
files or I can set svn:eol-style=native for all files recursively after
the import. Now I have to manually set svn:eol-style=LF on all files
named
configure or create a script that will do it.
Then, I upgrade the package to version 1.1. The existing files will
retain
their svn:eol-style properties, but for new files, I need to manually
set
the svn:eol-style properties, both for files named configure
(svn:eol-style=LF), and all other files (svn:eol-style=native), since I
cannot just set svn:eol-style=native on all files recursively this time
(I would loose my existing svn:eol-style property values).
Casper
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Re: Default eol styles
Posted by Erik Huelsmann <e....@gmx.net>.
[ Turned away from dev@ list since this is more of a user question now ]
Hi Carsten,
Ok; to understand your problem I replayed your commands here.
> I'm trying the auto-props feature. I'm using the command line
> client. My config file has:
>
> [miscellany]
> enable-auto-props = yes
>
> [auto-props]
> configure = svn:eol-style=LF
> * = svn:eol-style=native
>
> I'm trying to have files default to svn:eol-style=native,
> except for files named configure which should have
> svn:eol-style=LF. I import two files of which one is named
> configure. They both get svn:eol-style=native. I try to
> reverse it:
>
> [auto-props]
> * = svn:eol-style=native
> configure = svn:eol-style=LF
>
> and import again, but they still both get svn:eol-style=native.
This is what I saw too. Then looking at the code, I concluded that it does
not take the order of definition into account. Nor does it use any indicator
of 'how well the file matched' to set the properties. In the current code,
when you specify overlapping patterns with the same properties, but with
different values, the result is undefined.... I'm sorry to see that this will not
help you much.
> How can I set a default svn:eol-style for new files and still
> have rules for other files?
I don't understand this question. Auto-props are used to set properties on
files. Which means that if you change the auto-props settings only newly added
files will be affected. All files which are already added have their
properties set and thus continue to use whatever rules were set when they were
added... If you want to change those rules, you can change the properties of those
files in the repository.
bye,
Erik.
--
+++ GMX - die erste Adresse für Mail, Message, More +++
Neu: Preissenkung für MMS und FreeMMS! http://www.gmx.net
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Re: Default eol styles
Posted by Martin Furter <mf...@rola.ch>.
On Sun, 11 Jan 2004, Casper Hornstrup wrote:
>
> I'm trying the auto-props feature. I'm using the command line
> client. My config file has:
>
> [miscellany]
> enable-auto-props = yes
>
> [auto-props]
> configure = svn:eol-style=LF
> * = svn:eol-style=native
>
> I'm trying to have files default to svn:eol-style=native,
> except for files named configure which should have
> svn:eol-style=LF. I import two files of which one is named
> configure. They both get svn:eol-style=native. I try to
> reverse it:
>
> [auto-props]
> * = svn:eol-style=native
> configure = svn:eol-style=LF
>
> and import again, but they still both get svn:eol-style=native.
> How can I set a default svn:eol-style for new files and still
> have rules for other files?
All rules get applied. Because the rules are stored in a hashtable they
get applied in a 'random' order. So adding a rule might change the order
in which they are applied.
The * is in this case not really useful.
Martin
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Re: Default eol styles
Posted by Martin Furter <mf...@rola.ch>.
On Sun, 11 Jan 2004, Casper Hornstrup wrote:
>
> I'm trying the auto-props feature. I'm using the command line
> client. My config file has:
>
> [miscellany]
> enable-auto-props = yes
>
> [auto-props]
> configure = svn:eol-style=LF
> * = svn:eol-style=native
>
> I'm trying to have files default to svn:eol-style=native,
> except for files named configure which should have
> svn:eol-style=LF. I import two files of which one is named
> configure. They both get svn:eol-style=native. I try to
> reverse it:
>
> [auto-props]
> * = svn:eol-style=native
> configure = svn:eol-style=LF
>
> and import again, but they still both get svn:eol-style=native.
> How can I set a default svn:eol-style for new files and still
> have rules for other files?
All rules get applied. Because the rules are stored in a hashtable they
get applied in a 'random' order. So adding a rule might change the order
in which they are applied.
The * is in this case not really useful.
Martin
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Re: Default eol styles
Posted by Casper Hornstrup <ch...@users.sourceforge.net>.
> -----Oprindelig meddelelse-----
> Fra: Erik Huelsmann [mailto:e.huelsmann@gmx.net]
> Sendt: 10. januar 2004 19:42
> Til: Casper Hornstrup
> Cc: dev@subversion.tigris.org; users@subversion.tigris.org
> Emne: Re: Default eol styles
>
>
> [ snip proposal for new property ]
>
> Casper,
>
> I'm sorry to snip your complete proposal, but did you look at
> the configuration file of recent Subversion versions? On
> Windows it's located in %APPDATA%\Subversion\config (Windows
> guru's: did I specify this correctly?). For my useraccount
> it's at c:\Documents and Settings\Erik\Application
> Data\Subversion\config.
>
> In the [auto-props] section you can define behaviour which
> does almost what you want in sofar that it is the same, but
> client-side. I don´t know whether TortoiseSVN or RapidSVN
> actually use that file, but if they use (and I believe they
> do) the libsvn_client library to take care of Subversion
> interaction they can provide the same functionality. That
> library has this functionality built into it, so that any
> client (be it on Windows or Unix) just has to supply these settings.
>
> Hope that helps.
>
> bye,
>
> Erik.
I'm trying the auto-props feature. I'm using the command line
client. My config file has:
[miscellany]
enable-auto-props = yes
[auto-props]
configure = svn:eol-style=LF
* = svn:eol-style=native
I'm trying to have files default to svn:eol-style=native,
except for files named configure which should have
svn:eol-style=LF. I import two files of which one is named
configure. They both get svn:eol-style=native. I try to
reverse it:
[auto-props]
* = svn:eol-style=native
configure = svn:eol-style=LF
and import again, but they still both get svn:eol-style=native.
How can I set a default svn:eol-style for new files and still
have rules for other files?
Casper
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Re: Default eol styles
Posted by Casper Hornstrup <ch...@users.sourceforge.net>.
> -----Oprindelig meddelelse-----
> Fra: Erik Huelsmann [mailto:e.huelsmann@gmx.net]
> Sendt: 10. januar 2004 19:42
> Til: Casper Hornstrup
> Cc: dev@subversion.tigris.org; users@subversion.tigris.org
> Emne: Re: Default eol styles
>
>
> [ snip proposal for new property ]
>
> Casper,
>
> I'm sorry to snip your complete proposal, but did you look at
> the configuration file of recent Subversion versions? On
> Windows it's located in %APPDATA%\Subversion\config (Windows
> guru's: did I specify this correctly?). For my useraccount
> it's at c:\Documents and Settings\Erik\Application
> Data\Subversion\config.
>
> In the [auto-props] section you can define behaviour which
> does almost what you want in sofar that it is the same, but
> client-side. I don´t know whether TortoiseSVN or RapidSVN
> actually use that file, but if they use (and I believe they
> do) the libsvn_client library to take care of Subversion
> interaction they can provide the same functionality. That
> library has this functionality built into it, so that any
> client (be it on Windows or Unix) just has to supply these settings.
>
> Hope that helps.
>
> bye,
>
> Erik.
I'm trying the auto-props feature. I'm using the command line
client. My config file has:
[miscellany]
enable-auto-props = yes
[auto-props]
configure = svn:eol-style=LF
* = svn:eol-style=native
I'm trying to have files default to svn:eol-style=native,
except for files named configure which should have
svn:eol-style=LF. I import two files of which one is named
configure. They both get svn:eol-style=native. I try to
reverse it:
[auto-props]
* = svn:eol-style=native
configure = svn:eol-style=LF
and import again, but they still both get svn:eol-style=native.
How can I set a default svn:eol-style for new files and still
have rules for other files?
Casper
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Re: Default eol styles
Posted by Erik Huelsmann <e....@gmx.net>.
[ snip ]
> I did find the [auto-props] feature in the archives (I couldn't
> figure out if it was implemented on Windows though).
There is no difference in functionality between Subversion on Windows and
Unix, except for the fact that the Unix variant can't read configuration
settings from the registry :-)
> I don't like
> it for the following reasons:
>
> 1) Its a per user configuration.
On Unix Subversion also tries to open a global settings file
/etc/subversion; on Windows it tries (as documented in the readme in %APPDATA%\Subversion)
to read global configuration information from %ALLUSERSPROFILE%\Application
Data\Subversion\config
So it becomes a per-machine configuration. Which you have to do anyway since
you'll be needing to install subversion or any other client...
> Every user must configure these
> rules and it is easy to forget this. If the rules change, then
> all users have to change their configuration. Do they remember
> this and will they do it when asked so there will be no problems
> caused by forgetting this when they commit later? What if a user
> missed the information on the change of rules?
Well sure, but that's what the administrator can do on all machines in the
ALLUSERSPROFILE ...
> 2) Its an all or nothing approach. You can't make exceptions to the
> rule so all projects you work on, on a particular computer, will
> use the same rules. If you work on two projects that have a
> conflict in the rules you either need to use two user accounts,
> manually change the configuration file, or remember the rules and
> apply them manually. I'd much rather have Subversion remember and
> apply the rules I've setup for me.
Which is a problem when you first setup your project, but after that there
will be many commits, renames, checkouts and other stuff you'll do which all
nicely obide by the properties you defined when starting you project. I.e.:
are you trying to optimize something that might be problematic now, but you
won't reuse for quite some time after that?
> 3) Its not safe. When the rules are on the client computer they can
> get lost by a format and/or reinstall. When the rules are in the
> repository, they don't get lost.
Well, sure. But as pointed out, so will all other information on that
system. It will need a complete reinstall and when that happens, it is a good
moment to install the global settings file as I wrote about above...
bye,
Erik.
--
+++ GMX - die erste Adresse für Mail, Message, More +++
Neu: Preissenkung für MMS und FreeMMS! http://www.gmx.net
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Re: Default eol styles
Posted by Erik Huelsmann <e....@gmx.net>.
[ snip ]
> I did find the [auto-props] feature in the archives (I couldn't
> figure out if it was implemented on Windows though).
There is no difference in functionality between Subversion on Windows and
Unix, except for the fact that the Unix variant can't read configuration
settings from the registry :-)
> I don't like
> it for the following reasons:
>
> 1) Its a per user configuration.
On Unix Subversion also tries to open a global settings file
/etc/subversion; on Windows it tries (as documented in the readme in %APPDATA%\Subversion)
to read global configuration information from %ALLUSERSPROFILE%\Application
Data\Subversion\config
So it becomes a per-machine configuration. Which you have to do anyway since
you'll be needing to install subversion or any other client...
> Every user must configure these
> rules and it is easy to forget this. If the rules change, then
> all users have to change their configuration. Do they remember
> this and will they do it when asked so there will be no problems
> caused by forgetting this when they commit later? What if a user
> missed the information on the change of rules?
Well sure, but that's what the administrator can do on all machines in the
ALLUSERSPROFILE ...
> 2) Its an all or nothing approach. You can't make exceptions to the
> rule so all projects you work on, on a particular computer, will
> use the same rules. If you work on two projects that have a
> conflict in the rules you either need to use two user accounts,
> manually change the configuration file, or remember the rules and
> apply them manually. I'd much rather have Subversion remember and
> apply the rules I've setup for me.
Which is a problem when you first setup your project, but after that there
will be many commits, renames, checkouts and other stuff you'll do which all
nicely obide by the properties you defined when starting you project. I.e.:
are you trying to optimize something that might be problematic now, but you
won't reuse for quite some time after that?
> 3) Its not safe. When the rules are on the client computer they can
> get lost by a format and/or reinstall. When the rules are in the
> repository, they don't get lost.
Well, sure. But as pointed out, so will all other information on that
system. It will need a complete reinstall and when that happens, it is a good
moment to install the global settings file as I wrote about above...
bye,
Erik.
--
+++ GMX - die erste Adresse für Mail, Message, More +++
Neu: Preissenkung für MMS und FreeMMS! http://www.gmx.net
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Re: Default eol styles
Posted by Colin Watson <cj...@flatline.org.uk>.
On Sat, Jan 10, 2004 at 10:30:57PM +0100, Martin Furter wrote:
> On Sat, 10 Jan 2004, Casper Hornstrup wrote:
> > I did find the [auto-props] feature in the archives (I couldn't
> > figure out if it was implemented on Windows though). I don't like
> > it for the following reasons:
> >
> > 1) Its a per user configuration. Every user must configure these
> > rules and it is easy to forget this. If the rules change, then
> > all users have to change their configuration. Do they remember
> > this and will they do it when asked so there will be no problems
> > caused by forgetting this when they commit later? What if a user
> > missed the information on the change of rules?
>
> You can store the subversion config in a subversion repository (i think
> that's th reason why it is ~/.subversion on UNIX and not ~/.svn).
Actually, it's not easy to do that. When you try to do the checkout, svn
creates a template ~/.subversion directory before checking out the files
from the copy of your home directory, and you immediately get
"Obstructed update", which is awkward to work around. (At least, this
was the case ten releases or so ago when I tried to do it.) I eventually
gave up on storing ~/.subversion in my home directory repository.
--
Colin Watson [cjwatson@flatline.org.uk]
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Re: Default eol styles
Posted by Casper Hornstrup <ch...@users.sourceforge.net>.
> -----Oprindelig meddelelse-----
> Fra: Martin Furter [mailto:mf@rola.ch]
> Sendt: 10. januar 2004 22:31
> Til: Casper Hornstrup
> Cc: 'Erik Huelsmann'; dev@subversion.tigris.org;
> users@subversion.tigris.org
> Emne: Re: Default eol styles
>
> If you want to use auto-props don't forget to enable them:
> [miscellany] enable-auto-props = yes
That is nice to know.
> > 1) Its a per user configuration. Every user must configure these
> > rules and it is easy to forget this. If the rules change, then
> > all users have to change their configuration. Do they remember
> > this and will they do it when asked so there will be no problems
> > caused by forgetting this when they commit later? What if a user
> > missed the information on the change of rules?
> You can store the subversion config in a subversion
> repository (i think that's th reason why it is ~/.subversion
> on UNIX and not ~/.svn).
That would work if you already had a working copy, but as you point out
below, the user needs to take special care to load the configuration.
Manual labor, that I as a user, don't like to do. I want Subversion to
remember it for me or I forget and I'll have something similar to the
binary issue we have with CVS. A binary file that should have been added
in binary mode gets added in text mode because I forget to specify -kb
to cvs. I won't find out right away because cvs doesn't tell me that I
should add it in binary mode and it works fine with my configuration. I
will however find out when I've wasted X minutes of other developers
time because I broke the build. They are nice enough to tell me that I
screwed up (in the nicest way of course ;-).
I'm also pretty sure that the configuration file is not intended to be
put in the repository. It seems that it can contain absolute paths to
executables. It also contains editor preferences.
>
> > 2) Its an all or nothing approach. You can't make exceptions to the
> > rule so all projects you work on, on a particular computer, will
> > use the same rules. If you work on two projects that have a
> > conflict in the rules you either need to use two user accounts,
> > manually change the configuration file, or remember the rules and
> > apply them manually. I'd much rather have Subversion remember and
> > apply the rules I've setup for me.
> No, the config directory can be specified with --config-dir
> for the commandline client. But ofcourse you'd have to
> remember always specifying the right config. I don't know if
> other clients support that feature too.
I know TortoiseSVN doesn't.
>
> > 3) Its not safe. When the rules are on the client computer they can
> > get lost by a format and/or reinstall. When the rules are in the
> > repository, they don't get lost.
> Yeah, but other information then also gets lost, f.ex. the
> network configuration (yeah, i know that DHCP partially
> solves this) or configuration of other apps. I propose the
> same solution as for 1).
Yes. Someone should figure out how to put that configuration under
Version control ;-)
>
> Ofcourse i also would like to have this configuration stored
> in the repository and used only for that repos.
>
> Martin
Casper
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Re: Default eol styles
Posted by Casper Hornstrup <ch...@users.sourceforge.net>.
> -----Oprindelig meddelelse-----
> Fra: Martin Furter [mailto:mf@rola.ch]
> Sendt: 10. januar 2004 22:31
> Til: Casper Hornstrup
> Cc: 'Erik Huelsmann'; dev@subversion.tigris.org;
> users@subversion.tigris.org
> Emne: Re: Default eol styles
>
> If you want to use auto-props don't forget to enable them:
> [miscellany] enable-auto-props = yes
That is nice to know.
> > 1) Its a per user configuration. Every user must configure these
> > rules and it is easy to forget this. If the rules change, then
> > all users have to change their configuration. Do they remember
> > this and will they do it when asked so there will be no problems
> > caused by forgetting this when they commit later? What if a user
> > missed the information on the change of rules?
> You can store the subversion config in a subversion
> repository (i think that's th reason why it is ~/.subversion
> on UNIX and not ~/.svn).
That would work if you already had a working copy, but as you point out
below, the user needs to take special care to load the configuration.
Manual labor, that I as a user, don't like to do. I want Subversion to
remember it for me or I forget and I'll have something similar to the
binary issue we have with CVS. A binary file that should have been added
in binary mode gets added in text mode because I forget to specify -kb
to cvs. I won't find out right away because cvs doesn't tell me that I
should add it in binary mode and it works fine with my configuration. I
will however find out when I've wasted X minutes of other developers
time because I broke the build. They are nice enough to tell me that I
screwed up (in the nicest way of course ;-).
I'm also pretty sure that the configuration file is not intended to be
put in the repository. It seems that it can contain absolute paths to
executables. It also contains editor preferences.
>
> > 2) Its an all or nothing approach. You can't make exceptions to the
> > rule so all projects you work on, on a particular computer, will
> > use the same rules. If you work on two projects that have a
> > conflict in the rules you either need to use two user accounts,
> > manually change the configuration file, or remember the rules and
> > apply them manually. I'd much rather have Subversion remember and
> > apply the rules I've setup for me.
> No, the config directory can be specified with --config-dir
> for the commandline client. But ofcourse you'd have to
> remember always specifying the right config. I don't know if
> other clients support that feature too.
I know TortoiseSVN doesn't.
>
> > 3) Its not safe. When the rules are on the client computer they can
> > get lost by a format and/or reinstall. When the rules are in the
> > repository, they don't get lost.
> Yeah, but other information then also gets lost, f.ex. the
> network configuration (yeah, i know that DHCP partially
> solves this) or configuration of other apps. I propose the
> same solution as for 1).
Yes. Someone should figure out how to put that configuration under
Version control ;-)
>
> Ofcourse i also would like to have this configuration stored
> in the repository and used only for that repos.
>
> Martin
Casper
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Re: Default eol styles
Posted by Martin Furter <mf...@rola.ch>.
On Sat, 10 Jan 2004, Casper Hornstrup wrote:
> > -----Oprindelig meddelelse-----
> > Fra: Erik Huelsmann [mailto:e.huelsmann@gmx.net]
> > Sendt: 10. januar 2004 19:42
> > Til: Casper Hornstrup
> > Cc: dev@subversion.tigris.org; users@subversion.tigris.org
> > Emne: Re: Default eol styles
> >
> >
> > [ snip proposal for new property ]
> >
> > Casper,
> >
> > I'm sorry to snip your complete proposal, but did you look at
> > the configuration file of recent Subversion versions? On
> > Windows it's located in %APPDATA%\Subversion\config (Windows
> > guru's: did I specify this correctly?). For my useraccount
> > it's at c:\Documents and Settings\Erik\Application
> > Data\Subversion\config.
> >
> > In the [auto-props] section you can define behaviour which
> > does almost what you want in sofar that it is the same, but
> > client-side. I don´t know whether TortoiseSVN or RapidSVN
> > actually use that file, but if they use (and I believe they
> > do) the libsvn_client library to take care of Subversion
> > interaction they can provide the same functionality. That
> > library has this functionality built into it, so that any
> > client (be it on Windows or Unix) just has to supply these settings.
If you want to use auto-props don't forget to enable them:
[miscellany]
enable-auto-props = yes
> I did find the [auto-props] feature in the archives (I couldn't
> figure out if it was implemented on Windows though). I don't like
> it for the following reasons:
>
> 1) Its a per user configuration. Every user must configure these
> rules and it is easy to forget this. If the rules change, then
> all users have to change their configuration. Do they remember
> this and will they do it when asked so there will be no problems
> caused by forgetting this when they commit later? What if a user
> missed the information on the change of rules?
You can store the subversion config in a subversion repository (i think
that's th reason why it is ~/.subversion on UNIX and not ~/.svn).
> 2) Its an all or nothing approach. You can't make exceptions to the
> rule so all projects you work on, on a particular computer, will
> use the same rules. If you work on two projects that have a
> conflict in the rules you either need to use two user accounts,
> manually change the configuration file, or remember the rules and
> apply them manually. I'd much rather have Subversion remember and
> apply the rules I've setup for me.
No, the config directory can be specified with --config-dir for the
commandline client. But ofcourse you'd have to remember always specifying
the right config.
I don't know if other clients support that feature too.
> 3) Its not safe. When the rules are on the client computer they can
> get lost by a format and/or reinstall. When the rules are in the
> repository, they don't get lost.
Yeah, but other information then also gets lost, f.ex. the network
configuration (yeah, i know that DHCP partially solves this) or
configuration of other apps.
I propose the same solution as for 1).
Ofcourse i also would like to have this configuration stored in the
repository and used only for that repos.
Martin
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Re: Default eol styles
Posted by Martin Furter <mf...@rola.ch>.
On Sat, 10 Jan 2004, Casper Hornstrup wrote:
> > -----Oprindelig meddelelse-----
> > Fra: Erik Huelsmann [mailto:e.huelsmann@gmx.net]
> > Sendt: 10. januar 2004 19:42
> > Til: Casper Hornstrup
> > Cc: dev@subversion.tigris.org; users@subversion.tigris.org
> > Emne: Re: Default eol styles
> >
> >
> > [ snip proposal for new property ]
> >
> > Casper,
> >
> > I'm sorry to snip your complete proposal, but did you look at
> > the configuration file of recent Subversion versions? On
> > Windows it's located in %APPDATA%\Subversion\config (Windows
> > guru's: did I specify this correctly?). For my useraccount
> > it's at c:\Documents and Settings\Erik\Application
> > Data\Subversion\config.
> >
> > In the [auto-props] section you can define behaviour which
> > does almost what you want in sofar that it is the same, but
> > client-side. I don´t know whether TortoiseSVN or RapidSVN
> > actually use that file, but if they use (and I believe they
> > do) the libsvn_client library to take care of Subversion
> > interaction they can provide the same functionality. That
> > library has this functionality built into it, so that any
> > client (be it on Windows or Unix) just has to supply these settings.
If you want to use auto-props don't forget to enable them:
[miscellany]
enable-auto-props = yes
> I did find the [auto-props] feature in the archives (I couldn't
> figure out if it was implemented on Windows though). I don't like
> it for the following reasons:
>
> 1) Its a per user configuration. Every user must configure these
> rules and it is easy to forget this. If the rules change, then
> all users have to change their configuration. Do they remember
> this and will they do it when asked so there will be no problems
> caused by forgetting this when they commit later? What if a user
> missed the information on the change of rules?
You can store the subversion config in a subversion repository (i think
that's th reason why it is ~/.subversion on UNIX and not ~/.svn).
> 2) Its an all or nothing approach. You can't make exceptions to the
> rule so all projects you work on, on a particular computer, will
> use the same rules. If you work on two projects that have a
> conflict in the rules you either need to use two user accounts,
> manually change the configuration file, or remember the rules and
> apply them manually. I'd much rather have Subversion remember and
> apply the rules I've setup for me.
No, the config directory can be specified with --config-dir for the
commandline client. But ofcourse you'd have to remember always specifying
the right config.
I don't know if other clients support that feature too.
> 3) Its not safe. When the rules are on the client computer they can
> get lost by a format and/or reinstall. When the rules are in the
> repository, they don't get lost.
Yeah, but other information then also gets lost, f.ex. the network
configuration (yeah, i know that DHCP partially solves this) or
configuration of other apps.
I propose the same solution as for 1).
Ofcourse i also would like to have this configuration stored in the
repository and used only for that repos.
Martin
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Re: Default eol styles
Posted by Casper Hornstrup <ch...@users.sourceforge.net>.
> -----Oprindelig meddelelse-----
> Fra: Erik Huelsmann [mailto:e.huelsmann@gmx.net]
> Sendt: 10. januar 2004 19:42
> Til: Casper Hornstrup
> Cc: dev@subversion.tigris.org; users@subversion.tigris.org
> Emne: Re: Default eol styles
>
>
> [ snip proposal for new property ]
>
> Casper,
>
> I'm sorry to snip your complete proposal, but did you look at
> the configuration file of recent Subversion versions? On
> Windows it's located in %APPDATA%\Subversion\config (Windows
> guru's: did I specify this correctly?). For my useraccount
> it's at c:\Documents and Settings\Erik\Application
> Data\Subversion\config.
>
> In the [auto-props] section you can define behaviour which
> does almost what you want in sofar that it is the same, but
> client-side. I don´t know whether TortoiseSVN or RapidSVN
> actually use that file, but if they use (and I believe they
> do) the libsvn_client library to take care of Subversion
> interaction they can provide the same functionality. That
> library has this functionality built into it, so that any
> client (be it on Windows or Unix) just has to supply these settings.
>
> Hope that helps.
>
> bye,
>
> Erik.
I did find the [auto-props] feature in the archives (I couldn't
figure out if it was implemented on Windows though). I don't like
it for the following reasons:
1) Its a per user configuration. Every user must configure these
rules and it is easy to forget this. If the rules change, then
all users have to change their configuration. Do they remember
this and will they do it when asked so there will be no problems
caused by forgetting this when they commit later? What if a user
missed the information on the change of rules?
2) Its an all or nothing approach. You can't make exceptions to the
rule so all projects you work on, on a particular computer, will
use the same rules. If you work on two projects that have a
conflict in the rules you either need to use two user accounts,
manually change the configuration file, or remember the rules and
apply them manually. I'd much rather have Subversion remember and
apply the rules I've setup for me.
3) Its not safe. When the rules are on the client computer they can
get lost by a format and/or reinstall. When the rules are in the
repository, they don't get lost.
Casper Hornstrup
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Re: Default eol styles
Posted by Casper Hornstrup <ch...@users.sourceforge.net>.
> -----Oprindelig meddelelse-----
> Fra: Erik Huelsmann [mailto:e.huelsmann@gmx.net]
> Sendt: 10. januar 2004 19:42
> Til: Casper Hornstrup
> Cc: dev@subversion.tigris.org; users@subversion.tigris.org
> Emne: Re: Default eol styles
>
>
> [ snip proposal for new property ]
>
> Casper,
>
> I'm sorry to snip your complete proposal, but did you look at
> the configuration file of recent Subversion versions? On
> Windows it's located in %APPDATA%\Subversion\config (Windows
> guru's: did I specify this correctly?). For my useraccount
> it's at c:\Documents and Settings\Erik\Application
> Data\Subversion\config.
>
> In the [auto-props] section you can define behaviour which
> does almost what you want in sofar that it is the same, but
> client-side. I don´t know whether TortoiseSVN or RapidSVN
> actually use that file, but if they use (and I believe they
> do) the libsvn_client library to take care of Subversion
> interaction they can provide the same functionality. That
> library has this functionality built into it, so that any
> client (be it on Windows or Unix) just has to supply these settings.
>
> Hope that helps.
>
> bye,
>
> Erik.
I did find the [auto-props] feature in the archives (I couldn't
figure out if it was implemented on Windows though). I don't like
it for the following reasons:
1) Its a per user configuration. Every user must configure these
rules and it is easy to forget this. If the rules change, then
all users have to change their configuration. Do they remember
this and will they do it when asked so there will be no problems
caused by forgetting this when they commit later? What if a user
missed the information on the change of rules?
2) Its an all or nothing approach. You can't make exceptions to the
rule so all projects you work on, on a particular computer, will
use the same rules. If you work on two projects that have a
conflict in the rules you either need to use two user accounts,
manually change the configuration file, or remember the rules and
apply them manually. I'd much rather have Subversion remember and
apply the rules I've setup for me.
3) Its not safe. When the rules are on the client computer they can
get lost by a format and/or reinstall. When the rules are in the
repository, they don't get lost.
Casper Hornstrup
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Re: Default eol styles
Posted by Erik Huelsmann <e....@gmx.net>.
[ snip proposal for new property ]
Casper,
I'm sorry to snip your complete proposal, but did you look at the
configuration file of recent Subversion versions? On Windows it's located in
%APPDATA%\Subversion\config (Windows guru's: did I specify this correctly?). For my
useraccount it's at c:\Documents and Settings\Erik\Application
Data\Subversion\config.
In the [auto-props] section you can define behaviour which does almost what
you want in sofar that it is the same, but client-side. I don´t know whether
TortoiseSVN or RapidSVN actually use that file, but if they use (and I
believe they do) the libsvn_client library to take care of Subversion interaction
they can provide the same functionality. That library has this functionality
built into it, so that any client (be it on Windows or Unix) just has to
supply these settings.
Hope that helps.
bye,
Erik.
--
+++ GMX - die erste Adresse für Mail, Message, More +++
Neu: Preissenkung für MMS und FreeMMS! http://www.gmx.net
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Re: Default eol styles
Posted by Erik Huelsmann <e....@gmx.net>.
[ snip proposal for new property ]
Casper,
I'm sorry to snip your complete proposal, but did you look at the
configuration file of recent Subversion versions? On Windows it's located in
%APPDATA%\Subversion\config (Windows guru's: did I specify this correctly?). For my
useraccount it's at c:\Documents and Settings\Erik\Application
Data\Subversion\config.
In the [auto-props] section you can define behaviour which does almost what
you want in sofar that it is the same, but client-side. I don´t know whether
TortoiseSVN or RapidSVN actually use that file, but if they use (and I
believe they do) the libsvn_client library to take care of Subversion interaction
they can provide the same functionality. That library has this functionality
built into it, so that any client (be it on Windows or Unix) just has to
supply these settings.
Hope that helps.
bye,
Erik.
--
+++ GMX - die erste Adresse für Mail, Message, More +++
Neu: Preissenkung für MMS und FreeMMS! http://www.gmx.net
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org