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/highlight/__init__.pyc
ó
ÛXc@@s•dZddlmZddlmZddlmZmZmZddl	m
Z
mZmZdZ
d„Zd	„Zd
„Zd„Zd„Zd
S(stsyntax highlighting for hgweb (requires Pygments)

It depends on the Pygments syntax highlighting library:
http://pygments.org/

There are the following configuration options::

  [web]
  pygments_style = <style> (default: colorful)
  highlightfiles = <fileset> (default: size('<5M'))
  highlightonlymatchfilename = <bool> (default False)

``highlightonlymatchfilename`` will only highlight files if their type could
be identified by their filename. When this is not enabled (the default),
Pygments will try very hard to identify the file type from content and any
match (even matches with a low confidence score) will be used.
i(tabsolute_importi(t	highlight(tcommontwebcommandstwebutil(tencodingt
extensionstfilesetsships-with-hg-corec
C@s¿|jdddƒ}|jdddƒ}|jddtƒ}|jƒ}tj|ƒ}tj|d|jƒgddƒ}	|jƒtj	|	|ƒkr»t
j||||d	|ƒndS(
Ntwebtpygments_styletcolorfulthighlightfilesssize('<5M')thighlightonlymatchfilenametsubsettstatustguessfilenameonly(tconfigt
configbooltFalset	changectxRtparsetmatchctxtpathtNonetgetsetRt
pygmentize(
Rtfieldtfctxttmpltstyletexprtfilenameonlytctxttreetmctx((s</usr/lib/python2.7/dist-packages/hgext/highlight/__init__.pyR2s$cC@sSdj|ddtjƒƒ}d|kr@t|d||ƒn|||||ƒS(NttmimetypeRthtmltfileline(tjoinRR(torigRtreqRRtmt((s</usr/lib/python2.7/dist-packages/hgext/highlight/__init__.pytfilerevision_highlight>scC@sedj|ddtjƒƒ}d|krUtj|j|ƒ}t|d||ƒn||||ƒS(NR#R$RR%tannotateline(R'RRtfilectxtrepoR(R(RR)RR*R((s</usr/lib/python2.7/dist-packages/hgext/highlight/__init__.pytannotate_highlightLs
cC@sQ|jdddƒ}tjd|ƒ}|jtjdƒd||jdƒgS(NRR	R
Rstext/csss/* pygments_style = %s */

R#(RRt
HtmlFormattertrespondRtHTTP_OKtget_style_defs(RR)Rtpg_styletfmter((s</usr/lib/python2.7/dist-packages/hgext/highlight/__init__.pytgenerate_cssTs
cC@sCtjtdtƒtjtdtƒtt_tjjdƒdS(Nt
_filerevisiontannotatethighlightcss(	RtwrapfunctionRR+R/R6R9t__all__tappend(((s</usr/lib/python2.7/dist-packages/hgext/highlight/__init__.pytextsetup[s
	N(t__doc__t
__future__RR#Rtmercurial.hgwebRRRt	mercurialRRRt
testedwithRR+R/R6R=(((s</usr/lib/python2.7/dist-packages/hgext/highlight/__init__.pyt<module>s