[PATCH] introduce upath repositories (issue793)

Adrian Buehlmann adrian at cadifra.com
Wed Jun 18 05:00:59 CDT 2008


On 18.06.2008 10:39, Adrian Buehlmann wrote:
> On 18.06.2008 10:19, Adrian Buehlmann wrote:
>> On 18.06.2008 10:03, Adrian Buehlmann wrote:
>>> On 18.06.2008 09:59, Adrian Buehlmann wrote:
>>>> # HG changeset patch
>>>> # User Adrian Buehlmann <adrian at cadifra.com>
>>>> # Date 1213742337 -7200
>>>> # Node ID f26690cd0a452fe1bb0efdcf36c83f4ba2a92f3a
>>>> # Parent  bb1575f74f27070e3c58083608837c192dd8df35
>>>> introduce upath repositories (issue793)
>>> Just a quick update to save the current intermediate state of work
>>> (not intended for inclusion, as mpm wants to decide long path first)
>> An ls on FreeBSD in .hg/store/data of a clone of the Mercurial crew repo:
>>
>> %ls
>> _.hgignore.i                    __t_o_d_o.i                     _hgweb.py.i
>> _.hgsigs.i                      _comparison.txt.i               _hgwebdir.cgi.i
>> _.hgtags.i                      _contrib/                       _mercurial/
>> __c_o_n_t_r_i_b_u_t_o_r_s.i     _convert-repo.i                 _notes.txt.i
>> __c_o_p_y_i_n_g._g_p_l.i        _doc/                           _purge.py.i
>> __c_o_p_y_i_n_g.i               _hg.i                           _rewrite-log.i
>> __m_a_n_i_f_e_s_t.in.i          _hgeditor.i                     _setup.py.i
>> __makefile.i                    _hgext/                         _templates/
>> __p_k_g-_i_n_f_o.i              _hgmerge.i                      _tests/
>> __r_e_a_d_m_e.i                 _hgweb.cgi.i                    _tkmerge.i
> 
> ...just noticed that in *current* Mercurial repos you can't see the dotfiles
> (e.g. ".hgignore") in the store with ls (in re: "leaving the names readable"
> on unix...)
> 
> %ls
> _c_o_n_t_r_i_b_u_t_o_r_s.i      contrib/                        hgwebdir.cgi.i
> _c_o_p_y_i_n_g._g_p_l.i         convert-repo.i                  mercurial/
> _c_o_p_y_i_n_g.i                doc/                            notes.txt.i
> _m_a_n_i_f_e_s_t.in.i           hg.i                            purge.py.i
> _makefile.i                     hgeditor.i                      rewrite-log.i
> _p_k_g-_i_n_f_o.i               hgext/                          setup.py.i
> _r_e_a_d_m_e.i                  hgmerge.i                       templates/
> _t_o_d_o.i                      hgweb.cgi.i                     tests/
> comparison.txt.i                hgweb.py.i                      tkmerge.i
> 

Just a minor question:

Per mpm's posts about repo layout requirements, which I have compiled
into a new wiki page at RepositoryLayoutRequirements, it seems to me that
the current filename encoding scheme used by Mercurial is slightly
suboptimal.

As mpm laid out, best disk performance is achieved if the files in the
store and in the working dir are in the same directory order
(mpm: "Ideally, the store layout should roughly mirror the working dir layout").

The current filename encoding (also upath as presented) uses "_x"
to encode "X". Wouldn't it be a bit more efficient to do "X" -> "x_"?

What was the reasoning for chosing "X" -> "_x" and not "X" -> "x_"?



More information about the Mercurial-devel mailing list