You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@subversion.apache.org by Konstantin Kolinko <kn...@gmail.com> on 2011/05/18 12:35:29 UTC

Add ".svn-base" suffix to the pristine files in 1.7

Hi, all!

Right now the files in the pristine storage of 1.7 wc are named just
by their checksums, e.g.

.svn/pristine/00/00014966dd2c75cedf7fc9989accf25e54685e58

I think it would be better to add ".svn-base" suffix to those names,
so the above becomes

.svn/pristine/00/00014966dd2c75cedf7fc9989accf25e54685e58.svn-base

The rationale is to be able to ignore those files using a filename mask,
like it was in svn 1.6.


If anyone will implement this, the filename is currently calculated in function
get_pristine_fname(..) in subversion/libsvn_wc/wc_db_pristine.c

Best regards,
Konstantin Kolinko

Re: Add ".svn-base" suffix to the pristine files in 1.7

Posted by Julian Foad <ju...@wandisco.com>.
On Wed, 2011-05-18 at 15:55 +0200, Hyrum K Wright wrote:
> On Wed, May 18, 2011 at 3:43 PM, Julian Foad <ju...@wandisco.com> wrote:
> > C. Michael Pilato wrote:
> >> On 05/18/2011 02:02 PM, C. Michael Pilato wrote:
> >> > On 05/18/2011 01:34 PM, C. Michael Pilato wrote:
> >> >> You mentioned not being able to provide a patch, but would you be
> >> >> willing/able to at least file an issue for this in our tracker?
> >> >
> >> > Actually, I'm messing around in the tracker at the moment.  I'll file the issue.
> >>
> >> Okay.  http://subversion.tigris.org/issues/show_bug.cgi?id=3889
> >
> > I'll implement it.
> 
> Great.  Don't forget to add the upgrade paths (potentially to piggy
> back on format 29).

Done in r1125455 and r1126553.

- Julian




Re: Add ".svn-base" suffix to the pristine files in 1.7

Posted by Hyrum K Wright <hy...@hyrumwright.org>.
On Wed, May 18, 2011 at 3:43 PM, Julian Foad <ju...@wandisco.com> wrote:
> C. Michael Pilato wrote:
>> On 05/18/2011 02:02 PM, C. Michael Pilato wrote:
>> > On 05/18/2011 01:34 PM, C. Michael Pilato wrote:
>> >> You mentioned not being able to provide a patch, but would you be
>> >> willing/able to at least file an issue for this in our tracker?
>> >
>> > Actually, I'm messing around in the tracker at the moment.  I'll file the issue.
>>
>> Okay.  http://subversion.tigris.org/issues/show_bug.cgi?id=3889
>
> I'll implement it.

Great.  Don't forget to add the upgrade paths (potentially to piggy
back on format 29).

-Hyrum

Re: Add ".svn-base" suffix to the pristine files in 1.7

Posted by Julian Foad <ju...@wandisco.com>.
C. Michael Pilato wrote:
> On 05/18/2011 02:02 PM, C. Michael Pilato wrote:
> > On 05/18/2011 01:34 PM, C. Michael Pilato wrote:
> >> You mentioned not being able to provide a patch, but would you be
> >> willing/able to at least file an issue for this in our tracker?
> > 
> > Actually, I'm messing around in the tracker at the moment.  I'll file the issue.
> 
> Okay.  http://subversion.tigris.org/issues/show_bug.cgi?id=3889

I'll implement it.

- Julian



Re: Add ".svn-base" suffix to the pristine files in 1.7

Posted by "C. Michael Pilato" <cm...@collab.net>.
On 05/18/2011 02:02 PM, C. Michael Pilato wrote:
> On 05/18/2011 01:34 PM, C. Michael Pilato wrote:
>> You mentioned not being able to provide a patch, but would you be
>> willing/able to at least file an issue for this in our tracker?
> 
> Actually, I'm messing around in the tracker at the moment.  I'll file the issue.

Okay.  http://subversion.tigris.org/issues/show_bug.cgi?id=3889

-- 
C. Michael Pilato <cm...@collab.net>
CollabNet   <>   www.collab.net   <>   Distributed Development On Demand


Re: Add ".svn-base" suffix to the pristine files in 1.7

Posted by "C. Michael Pilato" <cm...@collab.net>.
On 05/18/2011 01:34 PM, C. Michael Pilato wrote:
> On 05/18/2011 01:23 PM, Konstantin Kolinko wrote:
>> My specific use case is doing a text search in some file manager [1] on
>> MS Windows.  There I can specify mask and exclude mask for file name,
>> but cannot specify masks for the file path.
>>
>> Several workarounds are possible here, but I think there might be other
>> use cases, like configuring antivirus software, or less experienced users.
>>
>> [1] http://farmanager.com/screenshots.php?l=en
> 
> I think it would be fine if we renamed the pristine files to have a
> file-pattern-matchable suffix.  In the room here in Berlin, others seem to
> agree.  There's effectively no cost to Subversion, and clearly it would
> provide benefit in situations such as yours.
> 
> You mentioned not being able to provide a patch, but would you be
> willing/able to at least file an issue for this in our tracker?
> 

Actually, I'm messing around in the tracker at the moment.  I'll file the issue.

-- 
C. Michael Pilato <cm...@collab.net>
CollabNet   <>   www.collab.net   <>   Distributed Development On Demand


Re: Add ".svn-base" suffix to the pristine files in 1.7

Posted by "C. Michael Pilato" <cm...@collab.net>.
On 05/18/2011 01:23 PM, Konstantin Kolinko wrote:
> My specific use case is doing a text search in some file manager [1] on
> MS Windows.  There I can specify mask and exclude mask for file name,
> but cannot specify masks for the file path.
> 
> Several workarounds are possible here, but I think there might be other
> use cases, like configuring antivirus software, or less experienced users.
> 
> [1] http://farmanager.com/screenshots.php?l=en

I think it would be fine if we renamed the pristine files to have a
file-pattern-matchable suffix.  In the room here in Berlin, others seem to
agree.  There's effectively no cost to Subversion, and clearly it would
provide benefit in situations such as yours.

You mentioned not being able to provide a patch, but would you be
willing/able to at least file an issue for this in our tracker?

-- 
C. Michael Pilato <cm...@collab.net>
CollabNet   <>   www.collab.net   <>   Distributed Development On Demand


Re: Add ".svn-base" suffix to the pristine files in 1.7

Posted by Konstantin Kolinko <kn...@gmail.com>.
2011/5/18 Hyrum K Wright <hy...@hyrumwright.org>:
> On Wed, May 18, 2011 at 12:35 PM, Konstantin Kolinko
> <kn...@gmail.com> wrote:
>> Hi, all!
>>
>> Right now the files in the pristine storage of 1.7 wc are named just
>> by their checksums, e.g.
>>
>> .svn/pristine/00/00014966dd2c75cedf7fc9989accf25e54685e58
>>
>> I think it would be better to add ".svn-base" suffix to those names,
>> so the above becomes
>>
>> .svn/pristine/00/00014966dd2c75cedf7fc9989accf25e54685e58.svn-base
>>
>> The rationale is to be able to ignore those files using a filename mask,
>> like it was in svn 1.6.
>
> I would think you could ignore these files via other means, and am
> having a hard time understanding the problem you are encountering.
> What problem are you running into?

My specific use case is doing a text search in some file manager [1] on
MS Windows.  There I can specify mask and exclude mask for file name,
but cannot specify masks for the file path.

Several workarounds are possible here, but I think there might be other
use cases, like configuring antivirus software,  or less experienced users.

[1] http://farmanager.com/screenshots.php?l=en

> Maybe you?

Sorry, I do not have dev environment for C/C++ now.
I am grateful to the TortoiseSVN project for providing the binaries.

Best regards,
Konstantin Kolinko

Re: Add ".svn-base" suffix to the pristine files in 1.7

Posted by Greg Stein <gs...@gmail.com>.
On Wed, May 18, 2011 at 06:54, Hyrum K Wright <hy...@hyrumwright.org> wrote:
> On Wed, May 18, 2011 at 12:35 PM, Konstantin Kolinko
> <kn...@gmail.com> wrote:
>> Hi, all!
>>
>> Right now the files in the pristine storage of 1.7 wc are named just
>> by their checksums, e.g.
>>
>> .svn/pristine/00/00014966dd2c75cedf7fc9989accf25e54685e58
>>
>> I think it would be better to add ".svn-base" suffix to those names,
>> so the above becomes
>>
>> .svn/pristine/00/00014966dd2c75cedf7fc9989accf25e54685e58.svn-base
>>
>> The rationale is to be able to ignore those files using a filename mask,
>> like it was in svn 1.6.
>
> I would think you could ignore these files via other means, and am
> having a hard time understanding the problem you are encountering.
> What problem are you running into?

As I recall, we added .svn-base so that a simple "find . -name foo.c"
would not turn up the working copy file AND the pristine. CMike says
that we also wanted the extension on there so that if it appeared in
an editor, you would know that you're not editing a pristine.

In both of those cases, our new naming avoids a simple "find", and it
is very clear you're editing a pristine (given its funky name).

And rather than filtering on .svn-base, you can filter on .svn/pristine

Cheers,
-g

Re: Add ".svn-base" suffix to the pristine files in 1.7

Posted by Hyrum K Wright <hy...@hyrumwright.org>.
On Wed, May 18, 2011 at 12:35 PM, Konstantin Kolinko
<kn...@gmail.com> wrote:
> Hi, all!
>
> Right now the files in the pristine storage of 1.7 wc are named just
> by their checksums, e.g.
>
> .svn/pristine/00/00014966dd2c75cedf7fc9989accf25e54685e58
>
> I think it would be better to add ".svn-base" suffix to those names,
> so the above becomes
>
> .svn/pristine/00/00014966dd2c75cedf7fc9989accf25e54685e58.svn-base
>
> The rationale is to be able to ignore those files using a filename mask,
> like it was in svn 1.6.

I would think you could ignore these files via other means, and am
having a hard time understanding the problem you are encountering.
What problem are you running into?

-Hyrum

> If anyone will implement this, the filename is currently calculated in function
> get_pristine_fname(..) in subversion/libsvn_wc/wc_db_pristine.c
>
> Best regards,
> Konstantin Kolinko
>

Re: Add ".svn-base" suffix to the pristine files in 1.7

Posted by Daniel Shahaf <d....@daniel.shahaf.name>.
+1

Konstantin Kolinko wrote on Wed, May 18, 2011 at 14:35:29 +0400:
> Hi, all!
> 
> Right now the files in the pristine storage of 1.7 wc are named just
> by their checksums, e.g.
> 
> .svn/pristine/00/00014966dd2c75cedf7fc9989accf25e54685e58
> 
> I think it would be better to add ".svn-base" suffix to those names,
> so the above becomes
> 
> .svn/pristine/00/00014966dd2c75cedf7fc9989accf25e54685e58.svn-base
> 
> The rationale is to be able to ignore those files using a filename mask,
> like it was in svn 1.6.
> 
> 
> If anyone will implement this,

Maybe you?

> the filename is currently calculated in function
> get_pristine_fname(..) in subversion/libsvn_wc/wc_db_pristine.c
> 

Yeah, but AIUI one will have to implement upgrade code that converts
current (format 11--28 working copies) to the new scheme.

(We won't keep code that looks in 'both places' in the release, and we
have to convert dev working copies somehow.)

> Best regards,
> Konstantin Kolinko