[PATCH 1 of 1] doc: add "icasefs" additional help topic for case insensitive filesystem

Matt Mackall mpm at selenic.com
Tue Apr 17 16:21:54 UTC 2012


On Tue, 2012-04-17 at 17:51 +0900, FUJIWARA Katsunori wrote:
> At Mon, 16 Apr 2012 13:19:03 -0500,
> Matt Mackall wrote:
> > 
> > On Mon, 2012-04-16 at 23:02 +0900, FUJIWARA Katsunori wrote:
> > > # HG changeset patch
> > > # User FUJIWARA Katsunori <foozy at lares.dti.ne.jp>
> > > # Date 1334584599 -32400
> > > # Node ID 4e738ea05ee07701fdc90afcc641753fc5076eac
> > > # Parent  9b26d541e972428a21d44837650932b2f2f5aeb0
> > > doc: add "icasefs" additional help topic for case insensitive filesystem
> > 
> > I think we probably want a whole 'filesystem' topic instead, mentioning
> > symlinks, exec bits, and hardlinks. As this is a doc change, it can wait
> > until after the freeze.
> > 
> > This probably also wants to mention Mercurial's internal case precedence
> > rules:
> > 
> > - case in dirstate
> > - case on filesystem
> > - case on command line
> 
> Thank you for your comments.
> 
> I tried to write out-line of 'filesystem' help doc, and abstract of
> each (new) sub topics. Are there enough/supposed topics ?
> 
>   - Handling links (NEW)
> 
>     - symlink
> 
>       Mercurial can record symlink as the text of link destination
>       into history. 
> 
>       on some platform where symlink capability is not available
>       (e.g.: NTFS on Windows, VFAT on Linux), Mercurial writes symlink
>       out as the plain text file which contains destination of
>       symlink.

These things are so different that they probably shouldn't be grouped.

>     - hardlink
> 
>       - hardlinking in metadata
> 
>         - hardlink used in "hg clone"
>         - overview of "relink" extension

I'd rather have just a "see also".

>       - hardlinking in working directory
> 
>         - assosiation between hard linked files is not recorded into
>           history
> 
>         - "hg update" and "hg revert" unlink files before writing data
>           into target files, so hardlinked content is not modified
> 
>   - Management other than contents (NEW)
> 
>     - exec bit
> 
>       initial value and changes of exec bit are recorded into
>       hitstory.
> 
>       but it is ignored on some platform (VFAT on some Linux platform
>       or Cygwin), because it does not treat exec bit correctly.
> 
>   - Working on caee insensitive filesystem
> 
>     - Warning for case-folding collision
>     - Abort for case-folding collision
>       - Abort updating to another version
>       - Abort merging with another revision
>     - Workaround
>       - Updating with --check or --clean
>       - Renaming colliding files
>       - Updating manually

Updating manually is probably too advanced for the built-in help.

>     - Case determination process in Mercurial (NEW)
> 
>       when you specify 'file' as filename in command line on case
>       insensitive filesystem, case of it is determined in order below.
> 
>         1. 'file' is normalized in case (e.g.: lower): call it as 'normed'
> 
>         2. if dirstate(or "manifest of working"?) has the 'konwn-file'
>            which is equal to 'normed' if it is normalized in case,
>            Mercurial uses 'konwn-file' as 'file'.
> 
>         3. if filesystem has 'existing-file' which is equal to 'normed'
>            if it is normalized in case , Mercurial uses
>            'existing-file' as 'file'.
> 
>         4. otherwise, Mercurial uses 'file' as 'file' itself.

It's simpler to say something like:

On case-insensitive systems, Mercurial decides what case to use in the
following order:

- the case used in the dirstate, if a file is tracked
- or the case used in the filesystem, if the file exists
- or the case given on the command line

-- 
Mathematics is the supreme nostalgia of our time.





More information about the Mercurial-devel mailing list