Ë 6ûÄêXkãóà—dZddlZddlZddlmZddlmZmZddlm Z m Z m Z m Z dZ iZe je«Zeddd „¬ «dad „Zd „Zd „Zd„Zd„Zd„Zd„Zdefd„ZdZdZdZdZd„Zy)aÉallow the use of MBCS paths with problematic encodings Some MBCS encodings are not good for some path operations (i.e. splitting path, case conversion, etc.) with its encoded bytes. We call such a encoding (i.e. shift_jis and big5) as "problematic encoding". This extension can be used to fix the issue with those encodings by wrapping some functions to convert to Unicode string before path operation. This extension is useful for: - Japanese Windows users using shift_jis encoding. - Chinese Windows users using big5 encoding. - All users who use a repository with one of problematic encodings on case-insensitive file system. This extension is not needed for: - Any user who use only ASCII chars in path. - Any user who do not use any of problematic encodings. Note that there are some limitations on using this extension: - You should use single encoding in one repository. - If the repository path ends with 0x5c, .hg/hgrc cannot be read. - win32mbcs is not compatible with fixutf8 extension. By default, win32mbcs uses encoding.encoding decided by Mercurial. You can specify the encoding by config option:: [win32mbcs] encoding = sjis It is useful for the users who want to commit with UTF-8 log message. éN)Ú_)ÚgetattrÚsetattr)ÚencodingÚerrorÚpycompatÚ registrarsships-with-hg-coreó win32mbcsóencodingcó"—tjS©N)r©óú3usr/lib/python3.12/site-packages/hgext/win32mbcs.pyÚrJs €”H×%Ò%r)Údefaultcó˜—t|t«r:|jt«}||j t«k(r|St d«‚t|t «rt tt|««St|t«rtt|«St|t«r&|j«D]\}}t|«||<Œ|S)NzNot local encoding) Ú isinstanceÚbytesÚdecodeÚ _encodingÚencodeÚ UnicodeErrorÚtupleÚmapÚlistÚdictÚitems)ÚargÚuargÚkÚvs rrrPsŸ€Ü�#”uÔØ�z‰zœ)Ó$ˆØ �$—+‘+œiÓ(Ò (؈KÜÐ/Ó0Ð0Ü �CœÔ Ü”Sœ Ó%Ó&Ð&Ü �CœÔ Ü”6˜3ÓÐÜ �CœÔ Ø—I‘I–K‰DˆAˆqܘA“YˆC�ŠFð à €JrcóN—t|t«r|jt«St|t«rt t t|««St|t «rt t|«St|t«r&|j«D]\}}t|«||<Œ|Sr ) rÚstrrrrrrrr)rr!r"s rrr`s~€Ü�#”sÔØ�z‰zœ)Ó$Ð$Ü �CœÔ Ü”Sœ Ó%Ó&Ð&Ü �CœÔ Ü”6˜3ÓÐÜ �CœÔ Ø—I‘I–K‰DˆAˆqܘA“YˆC�ŠFð à €Jrcóx— t|«}|r|ddvr|tjz }|S#t$r|}YŒ+wxYw)Néÿÿÿÿz:/\)rrrÚossep)ÚsÚuss rÚ appendsepr*msI€ðÜ �A‹Yˆñ ˆb�‰f˜FÑ"Ø ŒX�^‰^ÑˆØ €Høô òØ Šðús ‚ +« 9¸9c óÖ—|D]}t||«sŒ||i|¤ŽcS ||||«i||«¤Ž«S#t$r&tjt d«t z«‚wxYw)Ns8[win32mbcs] filename conversion failed with %s encoding )rrrÚAbortrr)ÚfuncÚargtypeÚencÚdecÚargsÚkwdsrs rÚ basewrapperr3xs{€ãˆÜ �c˜7Õ #Ù˜Ð& Ñ&Ò &ðð ñ‘4™˜T›Ð0¡c¨$£iÑ0Ó1Ð1øÜ ò Ü�k‰kÜ ÐJÓ KÜñ ó ð ð ús Ÿ9¹/A(có:—t|ttt||«Sr )r3r$rr©r-r1r2s rÚwrapperr6‰ó€Ü �tœS¤&¬&°$¸Ó =Ð=rcó:—t|ttt||«Sr )r3r$rrr5s rÚreversewrapperr9�r7rcóx—|rt|«}t|d«|d<d|vrt|d«|d<||i|¤ŽS)NrÚpath)rr*r5s rÚwrapperforlistdirr<‘sK€ñ Ü�D‹zˆÜ˜D ™GÓ$ˆˆQ‰Ø ��~Ü   f¡Ó.ˆˆV‰ Ù �Ð ˜Ñ ÐrÚnamec󸇇—|jdd«\}}tj|}t||«Šˆˆfd„}‰j|_t |||«y)NÚ.écó•—‰‰||«Sr r)r1r2r-r6s €€rÚfzwrapname..f¡sø€Ù�t˜T 4Ó(Ð(r)ÚrsplitÚsysÚmodulesrÚ__name__r)r=r6ÚmodulerBr-s ` @rÚwrapnamerHœsOù€Ø—;‘;˜s AÓ&�L€FˆDÜ �[‰[˜Ñ €FÜ �6˜4Ó €Dõ)ð—‘€A„JÜ ˆF�D˜!Õra:os.path.join os.path.split os.path.splitext os.path.normpath os.makedirs mercurial.util.endswithsep mercurial.util.splitpath mercurial.util.fscasesensitive mercurial.util.fspath mercurial.util.pconvert mercurial.util.normpath mercurial.util.checkwinfilename mercurial.util.checkosfilename mercurial.util.splitzRmercurial.encoding.upper mercurial.encoding.lower mercurial.util._filenamebytestrzos.path.splituncsíbig5 big5-tw csbig5 big5hkscs big5-hkscs hkscs cp932 932 ms932 mskanji ms-kanji shift_jis csshiftjis shiftjis sjis s_jis shift_jis_2004 shiftjis2004 sjis_2004 sjis2004 shift_jisx0213 shiftjisx0213 sjisx0213 s_jisx0213 950 cp950 ms950 có¶—tjjs.tjdk7r|j t d««y|jdd«atj«tj«vr×tj«D]}t|t«Œtjr)t j«D]}t|t«Œtdt"«tdt"«t$j«D]}t|t&«Œdt(j*vr|j-dtz«yyy) Nscygwins.[win32mbcs] cannot activate on this platform. r r zmercurial.util.listdirzmercurial.windows.listdirz--debugs([win32mbcs] activated with encoding: %s )Úosr;Úsupports_unicode_filenamesrÚ sysplatformÚwarnrÚconfigrÚlowerÚproblematic_encodingsÚsplitÚfuncsrHr6Ú iswindowsÚwinfuncsr<Úrfuncsr9rDÚargvÚ writenoi18n)ÚuirBs rÚextsetuprYÂsù€ä �G‰G× .Ò .Ü×Ñ  Ò)à �‰”ÐDÓEÔFØð— ‘ ˜,¨ Ó4€Iä‡�ÓÔ1×7Ñ7Ó9Ñ9Ü—‘–ˆAÜ �QœÕ ðä × Ò Ü—^‘^Ö%�ܘœGÕ$ð&äÐ)Ô+<Ô=ÜÐ,Ô.?Ô@ä—‘–ˆAÜ �QœÕ 'ð 𠜟™Ñ Ø �N‰NØ<¼yÑHõ ð !ð:r)Ú__doc__rJrDÚmercurial.i18nrÚmercurial.pycompatrrÚ mercurialrrrr Ú testedwithÚ configtableÚ configitemrrrr*r3r6r9r<r$rHrRrUrTrPrYrrrÚras­ðñ"óH Û åß/÷óð#€ à€ Ø !ˆY× !Ñ ! +Ó .€ ñ ØØÙ %õð € ò ò ò ò ò">ò>òð �3ó ð €ð $€ð "€ðGÐó r