Since the Netbeans project has included support for Mercurial in the GUI we are
looking at moving our sources from CVS to Mercurial. For one of our projects
created in Netbeans we are having this problem.
I created a repository on a linux server by converting a CVS checkout with "hg
convert" and published it with hgwebdir.cgi. When I try to clone it on my
windows workstation (Windows XP) I get the error "abort: The filename or
extension is too long". The filename hg clone complains about is:
D:\hg_clones\minsta_orderkvantitet\.hg\store\data/_min_order/src/conf/xml-resources/web-service-references/_min_order_service/wsdl/xxxxxxxxxxxxx.xxxxxx.xxxx.xxxxx__8080/_min_order_service_service/_min_order_service/____container__publishing__subctx/_m_e_t_a-_i_n_f/wsdl/_min_order_service_service__schema1.xsd.i
(311 chars)
I tried the workaround to set usestore = False in Mercurial.ini but I still get
the error but the file name has shortened a little:
D:\hg_clones\minsta_orderkvantitet\.hg\data/MinOrder/src/conf/xml-resources/web-service-references/MinOrderService/wsdl/xxxxxxxxxxxxx.xxxxxx.xxxx.xxxxx_8080/MinOrderServiceService/MinOrderService/__container_publishing_subctx/META-INF/wsdl/MinOrderServiceService_schema1.xsd.i
(276 chars)
I have tried both the Mercurial 1.0 binary installer and to install from sources
using python 2.5.2 and mingw32. I get the error in both cases. According to
http://bugs.python.org/issue542314 it should be possible to use longer filenames
in python 2.5 by using the prefix "\\?\".
For us this is a showstopper since it is our developer tool (Netbeans) that
creates this deep directory structure if one use web services so we cannot do
anything about it. The only thing we can do is to clone to a directory with an
extremely short path, for example "D:\m", but that feels like a strange
workaround since both the OS and Netbeans supports these kind of directory
structures and it limits our choice where we can store our cloned repositories.
This workaround also is dependent of the names of the included web services so
if a web service with an extremly long name is included the workaround doesn't
work anymore.
Inside my CVS checkout I can navigate to the deepest directory with explorer or
in a command window but I can't open the *.xsd file (total filename length = 271
chars) in notepad and the context menu is missing most of the alternatives
including delete. Still Netbeans obviously can create and open the file and also
commit the file to CVS. The issue with files that cannot be used by "normal"
programs is up to the user to handle. If the user has tools that creates these
kind of directory structures Mercurial should be able to handle them. |