Re: [fossil-users] Fossil cannot add filenames with "\*[]?"

2009-08-17 Thread Bill Whiting
I thought about VMS as well, but the [] is just specifying 
subdirectories.  I think any code to port fossil to VMS should do the 
translation from [.SRC.MYAPP.DB]CONNECT.C and store the path as 
./src/myapp/db/connect.c.  Then the file will checkout on any platform.  
As for filenames, that's a little stickier.


//Bill

On 08/17/2009 09:35 AM, Stephan Beal wrote:
On Mon, Aug 17, 2009 at 3:12 PM, Mark Janssen > wrote:


Hmmm for [] VMS comes to mind.
So fossil takes the common denominator for file names on all
platforms?


It sounds that way.

Although that's certainly good for portability of the
repos, it does limit the artifact names you can use. Renaming the
artifacts to a name which is allowed, is not always an option. Perhaps
a warning would be more appropriate?


It's a tough philosophical question for fossil. What is it to do if it 
tries to extract an artifact and cannot? It cannot know (without 
guessing, based on the combination of current platform and underlying 
filesystem type) that the problem is related to invalid characters. 
And even if it does determine that the filename is invalid, what could 
it possibly do? It cannot extract the file and it cannot rename an 
artifact (they're immutable).


i don't see any way for fossil to do this, other than blatantly 
disallowing any questionable the characters.


Imagine that you've checked in a file named "DoesThisWork?", and that 
works fine on your *nix box. Now someone with Windows tries to check 
it out and cannot get that file because his OS won't let a file with 
"?" be opened/created. Now the data is locked into fossil and cannot 
be taken out without:


a) using a platform which supports "?"
b) downloading the file individually from the repo web interface (easy 
if it's a text file, not so easy for binary). The ZIP file solution is 
not helpful here unless your ZIP browser also allows you to rename 
files inside the zip or rename them upon extraction.


While i agree that it's sub-optimal, i don't see any other realistic 
behaviour for fossil here.


--
- stephan beal
http://wanderinghorse.net/home/stephan/


___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users
   


___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users


Re: [fossil-users] Fossil cannot add filenames with "\*[]?"

2009-08-17 Thread Mark Janssen
On Mon, Aug 17, 2009 at 3:35 PM, Stephan Beal wrote:
> On Mon, Aug 17, 2009 at 3:12 PM, Mark Janssen  wrote:
>>
>> Hmmm for [] VMS comes to mind.
>> So fossil takes the common denominator for file names on all
>> platforms?
>
> It sounds that way.
>
>>
>> Although that's certainly good for portability of the
>> repos, it does limit the artifact names you can use. Renaming the
>> artifacts to a name which is allowed, is not always an option. Perhaps
>> a warning would be more appropriate?
>
> It's a tough philosophical question for fossil. What is it to do if it tries
> to extract an artifact and cannot? It cannot know (without guessing, based
> on the combination of current platform and underlying filesystem type) that
> the problem is related to invalid characters. And even if it does determine
> that the filename is invalid, what could it possibly do? It cannot extract
> the file and it cannot rename an artifact (they're immutable).
>
> i don't see any way for fossil to do this, other than blatantly disallowing
> any questionable the characters.
>
> Imagine that you've checked in a file named "DoesThisWork?", and that works
> fine on your *nix box. Now someone with Windows tries to check it out and
> cannot get that file because his OS won't let a file with "?" be
> opened/created. Now the data is locked into fossil and cannot be taken out
> without:
>
> a) using a platform which supports "?"
> b) downloading the file individually from the repo web interface (easy if
> it's a text file, not so easy for binary). The ZIP file solution is not
> helpful here unless your ZIP browser also allows you to rename files inside
> the zip or rename them upon extraction.
>
> While i agree that it's sub-optimal, i don't see any other realistic
> behaviour for fossil here.
>
> --
> - stephan beal
> http://wanderinghorse.net/home/stephan/
>

The options you sketched above are indeed the only ones that will
prevent you from getting into a situation where you cannot checkout a
file without renaming it. However in cases like that I usually prefer
tools which will allow you to shoot yourself in the foot if you know
what you are doing. (and alert you in that case).
So another option would be to allow checking in anything which can be
a valid file on the current platform (and warn about tricky
characters). And provide means to extra an artifact to a different
name if required.
This would mean that a fossil open on a different platform results in
a working tree which differs from the revision in the repository,
which is not necessarily a bad thing (for me).
I am curious how other programs handle situations like this (git,
subversion, scp etc.)

Mark
___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users


Re: [fossil-users] Fossil cannot add filenames with "\*[]?"

2009-08-17 Thread Stephan Beal
On Mon, Aug 17, 2009 at 3:12 PM, Mark Janssen  wrote:

> Hmmm for [] VMS comes to mind.
> So fossil takes the common denominator for file names on all
> platforms?


It sounds that way.


> Although that's certainly good for portability of the
> repos, it does limit the artifact names you can use. Renaming the
> artifacts to a name which is allowed, is not always an option. Perhaps
> a warning would be more appropriate?


It's a tough philosophical question for fossil. What is it to do if it tries
to extract an artifact and cannot? It cannot know (without guessing, based
on the combination of current platform and underlying filesystem type) that
the problem is related to invalid characters. And even if it does determine
that the filename is invalid, what could it possibly do? It cannot extract
the file and it cannot rename an artifact (they're immutable).

i don't see any way for fossil to do this, other than blatantly disallowing
any questionable the characters.

Imagine that you've checked in a file named "DoesThisWork?", and that works
fine on your *nix box. Now someone with Windows tries to check it out and
cannot get that file because his OS won't let a file with "?" be
opened/created. Now the data is locked into fossil and cannot be taken out
without:

a) using a platform which supports "?"
b) downloading the file individually from the repo web interface (easy if
it's a text file, not so easy for binary). The ZIP file solution is not
helpful here unless your ZIP browser also allows you to rename files inside
the zip or rename them upon extraction.

While i agree that it's sub-optimal, i don't see any other realistic
behaviour for fossil here.

-- 
- stephan beal
http://wanderinghorse.net/home/stephan/
___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users


Re: [fossil-users] Fossil cannot add filenames with "\*[]?"

2009-08-17 Thread Mark Janssen
On Mon, Aug 17, 2009 at 3:08 PM, Stephan Beal wrote:
> On Mon, Aug 17, 2009 at 12:06 PM, Mark Janssen 
> wrote:
>>
>> I noticed fossil will not add files containing any of the characters
>> "\*[]?". If I remove the checks for these chars, I cannot find any
>> adverse effects. Is there a specific reason these characters are
>> forbidden?
>
> The "?:*" characters are forbidden by FAT/VFAT filesystems. i cannot account
> for the "[]" being forbidden - it may be limited on other platforms (i just
> tried it on WinXP and Solaris 10, and "[]" are allowed there).
>
>
>
> --
> - stephan beal
> http://wanderinghorse.net/home/stephan/
>

Hmmm for [] VMS comes to mind.
So fossil takes the common denominator for file names on all
platforms? Although that's certainly good for portability of the
repos, it does limit the artifact names you can use. Renaming the
artifacts to a name which is allowed, is not always an option. Perhaps
a warning would be more appropriate?
___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users


Re: [fossil-users] Fossil cannot add filenames with "\*[]?"

2009-08-17 Thread Stephan Beal
On Mon, Aug 17, 2009 at 12:06 PM, Mark Janssen wrote:

> I noticed fossil will not add files containing any of the characters
> "\*[]?". If I remove the checks for these chars, I cannot find any
> adverse effects. Is there a specific reason these characters are
> forbidden?
>

The "?:*" characters are forbidden by FAT/VFAT filesystems. i cannot account
for the "[]" being forbidden - it may be limited on other platforms (i just
tried it on WinXP and Solaris 10, and "[]" are allowed there).



-- 
- stephan beal
http://wanderinghorse.net/home/stephan/
___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users


[fossil-users] Fossil cannot add filenames with "\*[]?"

2009-08-17 Thread Mark Janssen
Hi,

I noticed fossil will not add files containing any of the characters
"\*[]?". If I remove the checks for these chars, I cannot find any
adverse effects. Is there a specific reason these characters are
forbidden?

Regards,
Mark
___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users