Mercurial works in Wine
Matt Mackall
mpm at selenic.com
Sun Jun 22 16:24:18 UTC 2008
On Sun, 2008-06-22 at 08:34 +0200, Adrian Buehlmann wrote:
> On 22.06.2008 06:46, Matt Mackall wrote:
> > I just managed to clone and verify the main hg repo in Wine with the
> > just the following packages (all free software, of course):
> >
> > Wine 1.0rc5-1 (Debian unstable)
> > Python 2.5
> > MinGW-5.1-4
> >
> > Running 'winecommand cmd' gives me a console window. Also, Wine emulates
> > enough of Windows' filesystem quirks to make this useful for debugging.
>
> Interesting!
>
> Your list of installed packages does not include pywin32.
>
> Is it possible to install pywin32 and use win32file in that environment?
Probably. I just did the easiest possible thing.
> What does os.name say?
'nt'
sys.getwindowsversion says:
(5, 1, 2600, 2, 'Service Pack 2')
> mercurial.util.winstdout._is_win_9x, openhardlinks ?
undefined; False
> Is posixfile_nt of mercurial.util_win32 used?
Doesn't seem to be.
> Can you run hg with my long path experimental patch [1]
> and clone a repo like e.g. http://www.cadifra.com/cgi-bin/repos/long2 ?
Probably. Running interactive Python in the shell, I can use \\?\ paths
to open reserved filenames that I can't otherwise. Also, long path
behavior:
b = "x" * 200
os.mkdir(b)
c = b + "/" + b
open(c, "w").write("foo") # fails
open("\\\\?\\c:\" + c, "w").write("foo") # fails
open(unicode("\\\\?\\c:\" + c), "w").write("foo") # succeeds
open(unicode(c), "w").write("foo") # succeeds (as I suggested)
So it seems to emulate Windows pretty well, including blowing up when
attempting to clone your long2 repo.
Also, Wine seems to do the right thing in terms of code pages. If I
create a ü file encoded appropriately for my UTF-8 locale in the
underlying ext3 filesystem, it shows up as ü in Wine, but in cp437. But
it doesn't come with a chcp utility, so I'm not sure how to experiment
with it.
At present, I'm poking at some case folding issues that still aren't
sorted.
--
Mathematics is the supreme nostalgia of our time.
More information about the Mercurial-devel
mailing list