HEX

Warning: set_time_limit() [function.set-time-limit]: Cannot set time limit - prohibited by configuration in /home/u547966/brikov.ru/www/wp-content/plugins/admin-menu-editor/menu-editor.php on line 745
Server: Apache
System: Linux 4.19.0-0.bpo.9-amd64 x86_64 at red40
User: u547966 (5490)
PHP: 5.3.29-mh2
Disabled: syslog, dl, popen, proc_open, proc_nice, proc_get_status, proc_close, proc_terminate, posix_mkfifo, chown, chgrp, accelerator_reset, opcache_reset, accelerator_get_status, opcache_get_status, pcntl_alarm, pcntl_fork, pcntl_waitpid, pcntl_wait, pcntl_wifexited, pcntl_wifstopped, pcntl_wifsignaled, pcntl_wifcontinued, pcntl_wexitstatus, pcntl_wtermsig, pcntl_wstopsig, pcntl_signal, pcntl_signal_dispatch, pcntl_get_last_error, pcntl_strerror, pcntl_sigprocmask, pcntl_sigwaitinfo, pcntl_sigtimedwait, pcntl_exec, pcntl_getpriority, pcntl_setpriority
Upload Files
File: //usr/lib/python2.7/dist-packages/hgext/eol.pyc
ó
ÛXc@@s?dZddlmZddlZddlZddlmZddlmZm	Z	m
Z
mZmZdZ
ejdƒZejdƒZd	„Zd
„Zd„Zd„Zied
6ed6ed6ed6ed6Zdefd„ƒYZd„Zd„Zd„Zd„ZeZd„Zd„Zd„Zd„Z dS(s6automatically manage newlines in repository files

This extension allows you to manage the type of line endings (CRLF or
LF) that are used in the repository and in the local working
directory. That way you can get CRLF line endings on Windows and LF on
Unix/Mac, thereby letting everybody use their OS native line endings.

The extension reads its configuration from a versioned ``.hgeol``
configuration file found in the root of the working directory. The
``.hgeol`` file use the same syntax as all other Mercurial
configuration files. It uses two sections, ``[patterns]`` and
``[repository]``.

The ``[patterns]`` section specifies how line endings should be
converted between the working directory and the repository. The format is
specified by a file pattern. The first match is used, so put more
specific patterns first. The available line endings are ``LF``,
``CRLF``, and ``BIN``.

Files with the declared format of ``CRLF`` or ``LF`` are always
checked out and stored in the repository in that format and files
declared to be binary (``BIN``) are left unchanged. Additionally,
``native`` is an alias for checking out in the platform's default line
ending: ``LF`` on Unix (including Mac OS X) and ``CRLF`` on
Windows. Note that ``BIN`` (do nothing to line endings) is Mercurial's
default behavior; it is only needed if you need to override a later,
more general pattern.

The optional ``[repository]`` section specifies the line endings to
use for files stored in the repository. It has a single setting,
``native``, which determines the storage line endings for files
declared as ``native`` in the ``[patterns]`` section. It can be set to
``LF`` or ``CRLF``. The default is ``LF``. For example, this means
that on Windows, files configured as ``native`` (``CRLF`` by default)
will be converted to ``LF`` when stored in the repository. Files
declared as ``LF``, ``CRLF``, or ``BIN`` in the ``[patterns]`` section
are always stored as-is in the repository.

Example versioned ``.hgeol`` file::

  [patterns]
  **.py = native
  **.vcproj = CRLF
  **.txt = native
  Makefile = LF
  **.jpg = BIN

  [repository]
  native = LF

.. note::

   The rules will first apply when files are touched in the working
   directory, e.g. by updating to null and back to tip to touch all files.

The extension uses an optional ``[eol]`` section read from both the
normal Mercurial configuration files and the ``.hgeol`` file, with the
latter overriding the former. You can use that section to control the
overall behavior. There are three settings:

- ``eol.native`` (default ``os.linesep``) can be set to ``LF`` or
  ``CRLF`` to override the default interpretation of ``native`` for
  checkout. This can be used with :hg:`archive` on Unix, say, to
  generate an archive where files have line endings for Windows.

- ``eol.only-consistent`` (default True) can be set to False to make
  the extension convert files with inconsistent EOLs. Inconsistent
  means that there is both ``CRLF`` and ``LF`` present in the file.
  Such files are normally not touched under the assumption that they
  have mixed EOLs on purpose.

- ``eol.fix-trailing-newline`` (default False) can be set to True to
  ensure that converted files end with a EOL character (either ``\n``
  or ``\r\n`` as per the configured patterns).

The extension provides ``cleverencode:`` and ``cleverdecode:`` filters
like the deprecated win32text extension does. This means that you can
disable win32text and enable eol and your filters will still work. You
only need to these filters until you have prepared a ``.hgeol`` file.

The ``win32text.forbid*`` hooks provided by the win32text extension
have been unified into a single hook named ``eol.checkheadshook``. The
hook will lookup the expected line endings from the ``.hgeol`` file,
which means you must migrate to a ``.hgeol`` file first before using
the hook. ``eol.checkheadshook`` only checks heads, intermediate
invalid revisions will be pushed. To forbid them completely, use the
``eol.checkallhook`` hook. These hooks are best used as
``pretxnchangegroup`` hooks.

See :hg:`help patterns` for more information about the glob patterns
used.
i(tabsolute_importN(t_(tconfigterrort
extensionstmatchtutilsships-with-hg-cores	(^|[^
])
s
*
cC@sd|kotj|ƒS(Ns
(tsinglelftsearch(tdata((s-/usr/lib/python2.7/dist-packages/hgext/eol.pytinconsistenteolyscK@s€tj|ƒr|S|jddtƒr8t|ƒr8|S|jddtƒrp|rp|ddkrp|d}ntjd|ƒS(sFilter to convert to LF EOLs.teolsonly-consistentsfix-trailing-newlineiÿÿÿÿs
(Rtbinaryt
configbooltTrueR
tFalseteolretsub(tstparamstuitkwargs((s-/usr/lib/python2.7/dist-packages/hgext/eol.pyttolf|s!
cK@s€tj|ƒr|S|jddtƒr8t|ƒr8|S|jddtƒrp|rp|ddkrp|d}ntjd|ƒS(sFilter to convert to CRLF EOLs.Rsonly-consistentsfix-trailing-newlineiÿÿÿÿs
s
(RRR
RR
RRR(RRRR((s-/usr/lib/python2.7/dist-packages/hgext/eol.pyttocrlf‡s!
cC@s|S(s#Filter to do nothing with the file.((RR((s-/usr/lib/python2.7/dist-packages/hgext/eol.pytisbinary’ssto-lfsto-crlfs	is-binarys
cleverencode:s
cleverdecode:teolfilecB@s#eZd„Zd„Zd„ZRS(cC@s¢idd6dd6dd6|_idd6dd6dd6|_tjƒ|_|jjdddd	ƒ|jjd
|ƒ|jjddƒdk}|rždp¡d|jd
<|jd	dtjƒdk}|rÕdpØd|jd
<g}g}g|_	x†|jj
dƒD]r\}}	|	jƒ}
|
dkr>|j|ƒn
|j|ƒt
j
|d|gƒ}|j	j||
|fƒq
Wt
j
|dg||ƒ|_
dS(Nsto-lftLFsto-crlftCRLFs	is-binarytBINtpatternss.hg*Rs.hgeolt
repositorytnativetNATIVEs
t(Rs
(t_decodet_encodeRtcfgtsettparsetgettostlinesepRtitemstuppertappendR(tselfRtrootR	tisrepolftiswdlftincludetexcludetpatterntstyletkeytm((s-/usr/lib/python2.7/dist-packages/hgext/eol.pyt__init__ s(	
cC@sØx˜|jD]\}}}y>|jd||j|dƒ|jd||j|dƒWq
tk
r–|jtdƒ||jjd|ƒfƒq
Xq
Wx6|jj	dƒD]"\}}|jd||dƒq®WdS(NtdecodeRtencodes(ignoring unknown EOL style '%s' from %s
R(
Rt	setconfigR"R#tKeyErrortwarnRR$tsourceR*(R-RR3R5R6tktv((s-/usr/lib/python2.7/dist-packages/hgext/eol.pytcopytoui¿s!
%cC@sØg}xË|p|jƒD]·}||kr1qnxœ|jD]‘\}}}||ƒs\q;n|j|}	||jƒ}
|	dkr‘d|
ks¬|	dkrËtj|
ƒrË|j||	t|ƒfƒnPq;WqW|S(Nsto-lfs
sto-crlf(tfilesRR#R	RRR,tstr(R-trepotctxRAtfailedtfR3R5R6ttargetR	((s-/usr/lib/python2.7/dist-packages/hgext/eol.pytcheckrevËs
	(t__name__t
__module__R7R@RH(((s-/usr/lib/python2.7/dist-packages/hgext/eol.pyRŸs		cC@sÆy~xw|D]o}yO|dkr7|jdƒjƒ}n||djƒ}t||j|ƒSWq
ttfk
rxq
Xq
WWnAtj	k
rÁ}|j
tdƒ|jd|jdfƒnXdS(Ns.hgeols;warning: ignoring .hgeol file due to parse error at %s: %s
ii(
tNonetwfiletreadR	RR.tIOErrortLookupErrorRt
ParseErrorR<Rtargs(RRCtnodestnodeR	tinst((s-/usr/lib/python2.7/dist-packages/hgext/eol.pytparseeolÛs
 cC@s‡tƒ}tƒ}x„t||jƒt|ƒƒD]c}|j|ƒ|r2||}|j|jƒƒx*|jƒD]}|j|jƒƒquWq2q2Wg}	xX|D]P}||}t	|||j
ƒgƒ}
|
r¦|	j|
j|||ƒƒq¦q¦W|	rƒidd6dd6}g}xAt
|	ƒD]3\}
}}|jtdƒ|
|||fƒq'Wtjtdƒdj|ƒƒ‚ndS(NRsto-lfRsto-crlfs*  %s in %s should not have %s line endingssend-of-line check failed:
s
(R%txrangetrevtlentaddtupdateRAtparentstdiscardRURStextendRHtsortedR,RRtAborttjoin(RRCRSt	headsonlyRAtrevsRWRDtpctxRERteolstmsgsRFRG((s-/usr/lib/python2.7/dist-packages/hgext/eol.pyt
_checkhookís,		&



#cK@st|||tƒdS(s$verify that files have expected EOLsN(RfR(RRCRSthooktypeR((s-/usr/lib/python2.7/dist-packages/hgext/eol.pytcheckallhookscK@st|||tƒdS(s$verify that files have expected EOLsN(RfR(RRCRSRgR((s-/usr/lib/python2.7/dist-packages/hgext/eol.pytcheckheadshookscC@s|j|gƒtS(N(tloadeolR(RRCRgtparent1tparent2((s-/usr/lib/python2.7/dist-packages/hgext/eol.pyt	preupdatescC@s|jddtdƒdS(Nthookss
preupdate.eolR(R:Rm(R((s-/usr/lib/python2.7/dist-packages/hgext/eol.pytuisetupscC@s<y$tjdƒ|jtdƒƒWntk
r7nXdS(Nt	win32texts?the eol extension is incompatible with the win32text extension
(RtfindR<RR;(R((s-/usr/lib/python2.7/dist-packages/hgext/eol.pytextsetups


c@s–t|jƒ|jƒsdSx*tjƒD]\}}|j||ƒq*W|jddddƒd|jf‡fd†ƒY‰ˆ|_|jƒdS(NtpatchRtautoteolrepoc@s,eZd„Zd„Ze‡fd†ZRS(cS@s<t|j||ƒ}|dkr%dS|j|jƒ|jS(N(RURRKR@R(R-RRR((s-/usr/lib/python2.7/dist-packages/hgext/eol.pyRj.s
cS@s•|jddgƒ|_|js1tj|_dSd}ytjj|jdƒƒ}Wnt	k
rod}n4X|j
jdƒ}|r£t|j
|j|ƒ}nytjj|jdƒƒ}Wnt	k
rÛd}nX||kr‘|j
jdƒ|jjdƒ}t|j
|j|ƒ}d}zIy.|jƒ}xó|jD]è}|j|dkrcqDn|dk	r|j|ƒr•|j|ƒr•qDnd}	x0|jD]%\}
}}||ƒr¥|}	Pq¥q¥Wd}
x0|jD]%\}
}}||ƒrÞ|}
PqÞqÞW|	|
krqDqn|jj|ƒqDW|j
ddƒ}|j|ƒWdQXWntjk
ronXWd|dk	r|jƒnXndS(Nttips	eol.cacheis.hgeolseol: detected change in .hgeol
tntw(RjRKt	_eolmatchRtneverR(tpathtgetmtimeR`tOSErrortvfsRMRRR.twjointdebugtwvfstwlocktdirstateRRtnormallookuptwriteRtLockUnavailabletrelease(R-toldeolt
cachemtimetolddatateolmtimet	hgeoldatatneweolR‚RFtoldkeyR3R5R6tnewkey((s-/usr/lib/python2.7/dist-packages/hgext/eol.pyt_hgcleardirstate5sb	



 	c@sºxžt|jƒ|jƒƒD]€}|j|ƒs8qn||}|dkrTqn|jƒ}tj|ƒruqnt|ƒrt	j
tdƒ|ƒ‚qqWtˆ|ƒj
||ƒS(Ns!inconsistent newline style in %s
(R^taddedtmodifiedRyRKR	RRR
RR_Rtsupert	commitctx(R-RDthaserrorRFtfctxR	(Ru(s-/usr/lib/python2.7/dist-packages/hgext/eol.pyR”vs#
(RIRJRjRRR”((Ru(s-/usr/lib/python2.7/dist-packages/hgext/eol.pyRu,s		A(	RoRtlocaltfilterst	iteritemst
adddatafilterR:t	__class__R(RRCtnametfn((Rus-/usr/lib/python2.7/dist-packages/hgext/eol.pyt	reposetup"s
[	(!t__doc__t
__future__RR(tretmercurial.i18nRt	mercurialRRRRRt
testedwithtcompileRRR
RRRR˜tobjectRRURfRhRithookRmRoRrRž(((s-/usr/lib/python2.7/dist-packages/hgext/eol.pyt<module>\s8(				
<