403Webshell
Server IP : 80.87.202.40  /  Your IP : 216.73.216.169
Web Server : Apache
System : Linux rospirotorg.ru 5.14.0-539.el9.x86_64 #1 SMP PREEMPT_DYNAMIC Thu Dec 5 22:26:13 UTC 2024 x86_64
User : bitrix ( 600)
PHP Version : 8.2.27
Disable Function : NONE
MySQL : OFF |  cURL : ON |  WGET : ON |  Perl : ON |  Python : OFF |  Sudo : ON |  Pkexec : ON
Directory :  /lib64/python3.9/site-packages/hgext/__pycache__/

Upload File :
current_dir [ Writeable] document_root [ Writeable]

 

Command :


[ Back ]     

Current File : /lib64/python3.9/site-packages/hgext/__pycache__/uncommit.cpython-39.pyc
a

�+�b�(�
@s"dZddlmZddlmZddlmZmZmZm	Z
mZmZm
Z
mZmZmZmZiZe�e�ZiZe�e�Zedddd�edd	dd�d
Zd#dd
�Zedddded�fddded�fddded�ed�fgejejejejed�ejd�dd��Zdd�Zedgejdd �d!d"��ZdS)$aHuncommit part or all of a local changeset (EXPERIMENTAL)

This command undoes the effect of a local commit, returning the affected
files to their uncommitted state. This means that files modified, added or
removed in the changeset will be left unchanged, and so will remain modified,
added and removed in the working directory.
�)�absolute_import)�_)�cmdutil�commands�context�copies�error�obsutil�pathutil�pycompat�	registrar�rewriteutil�scmutil�experimental�uncommitondirtywdirF)�default�
uncommit.keepsships-with-hg-coreNc
s�|��}t|���}�fdd�|D�}	|	s.dS|s>|����S||	�t�||���fdd�t���D��|df�fdd�	}
�s�|j�	t
d	��|dur�|��}|s�|��}|s�|�
�}tj||��|jg|�|
|||��d
�}|�|�S)zrRecommit ctx with changed files not in match. Return the new
    node identifier, or None if nothing changed.
    csh|]}�|�r|�qS�r��.0�f)�matchr�4/usr/lib64/python3.9/site-packages/hgext/uncommit.py�	<setcomp>G�z"_commitfiltered.<locals>.<setcomp>Ncsi|]\}}|�vr||�qSrr)r�dst�src)�filesrr�
<dictcomp>Tsz#_commitfiltered.<locals>.<dictcomp>rc
sF||vrdS||}tj|||��|��|��|����|�d�}|S)N)Z
copysource)rZ
memfilectx�path�data�islinkZisexec�get)�repo�memctxrZ
contentctxZredirectZfctxZmctx)�copiedrr�	filectxfnXs�	z"_commitfiltered.<locals>.filectxfnsnote: keeping empty commit
��parents�textrr&�user�date�extra)�p1�setr�node�	copiesmodZ
pathcopiesrZ	iteritems�ui�statusr�descriptionr*r+rr$Znullidr,�	commitctx)r#�ctxr�
keepcommit�messager*r+�baseZinitialfilesZexcluder&�newr)r%rrr�_commitfiltered>s@
��
r:�uncommitr�keeps(allow an empty commit after uncommittingsallow-dirty-working-copys'allow uncommit with outstanding changes�nsnotesstore a note on uncommitsTEXTs[OPTION]... [FILE]...)�helpcategoryc
Os|t�|�t�||�t�|�}|����<|����|��}|j|j	|j
|jf\}}}}tt
||||�t
|�@�}	|dp�|j�dd�}
|
s�|r�|	r�tj|td�d�|d}t�||��gd�t|���dkr�t�td	���t�|||�}|���r�|j|��|d
d�}
t
|
j	�t
|
j�Bt
|
j
�B}t
|���|}|�rb|dd
�t�|�D�8}t|�D]\}||
j v�r�td�}n |j!�"|��r�td�}ntd�}tjtd�t�#|�|�|d���qj|�$d���R|d�s�|d�s�|�%�|d<t�&||�}|}|�s4|�'d�du�r(|�'d�}n|�dd�}t(||||||�'d�|�'d�d�}|du�r�|�td��Wd�Wd�Wd�dSi}||���)�k�r�|f||�)�<nd||�)�<|j*�+��"t�,||||�Wd�n1�s�0Ytj-||dd
d�Wd�n1�s.0YWd�n1�sN0YWd�n1�sn0YdS)a�uncommit part or all of a local changeset

    This command undoes the effect of a local commit, returning the affected
    files to their uncommitted state. This means that files modified or
    deleted in the changeset will be left unchanged, and so will remain
    modified in the working directory.

    If no files are specified, the commit will be pruned, unless --keep is
    given.
    sallow_dirty_working_copyrrs/requires --allow-dirty-working-copy to uncommit)�hint�.r;�scannot uncommit merge changesetT)Z	listcleancSsh|]}|�qSrrrrrrr�rzuncommit.<locals>.<setcomp>s0file was not changed in working directory parents.file was untracked in working directory parentsfile does not existscannot uncommit "%s"smessageslogfiler<Nrsusersdate)r7r*r+snothing to uncommit
r�Zfixphase).rZcheck_note_sizeZresolve_commit_optionsrZbyteskwargs�wlock�lockr2ZmodifiedZaddedZremovedZdeleted�anyr.r1Z
configboolZ
bailifchangedrr
�precheck�rev�lenr(r�
InputErrorrrrr-r
�dirs�sortedZcleanZwvfs�existsZgetuipathfn�transactionr3Z
logmessager"r:r/�dirstate�parentchange�movedirstate�cleanupnodes)r1r#Zpats�opts�st�m�a�r�dZisdirtypathZallowdirtywcopy�oldr�sZeligibleZbadfilesrr?r7r6Znewid�mappingrrr�uncommit~s�

 ���
�
�
��	
(2r[ccs4|��jj�|��d�D]}t�|��|�VqdS)zFyields the obsolete markers marking the given changeset as a successorrN)r#ZobsstoreZpredecessorsr"r/r	Zmarker)r5r rrr�predecessormarkers�sr\�unamendT)r>Z	helpbasicc
s�|��}|�����|�����|�d���||d�t�|���gd�t����dkrht	�
td���d}t�fdd�|D��s�t	�
td���t
t���}t|�dkr�td	�}t	�
|t|���|d
��}||����}���|d<�fdd
�}	tj|������f������|	������|d�}
|�|
�}||}|j}
|
���t�||�Wd�n1�sp0Y���|fi}tj ||ddd�Wd�n1�s�0YWd�n1�s�0YWd�n1�s�0YdS)a3undo the most recent amend operation on a current changeset

    This command will roll back to the previous version of a changeset,
    leaving working directory in state in which it was before running
    `hg amend` (e.g. files modified as part of an amend will be
    marked as modified `hg status`)
    r]r@rAscannot unamend merge changeset)samend_source�unamend_sourcec3s|]}|���vVqdS�N)r,)r�key)�curctxrr�	<genexpr>rzunamend.<locals>.<genexpr>sAworking copy parent was not created by 'hg amend' or 'hg unamend's:changeset must have one predecessor, found %i predecessorsrr^cs&z��|�WSty YdS0dSr_)Zfilectx�KeyError)r#Zctx_r)�predctxrrr&.szunamend.<locals>.filectxfnr'NTrB)!Z
unfilteredrCrDrMr
rFrGrHr(rrIrrE�listr\�prednoder,�hexrr$r-Zp2r3rr*r+r4rNrOrrPr/rQ)r1r#rRZunfiZ
expected_keysZmarkers�erf�extrasr&ZnewctxZnewprednodeZ
newpredctxrNrZr)rardr�unamend�sN&���


,rj)NNN) �__doc__Z
__future__rZmercurial.i18nrZ	mercurialrrrrr0rr	r
rrr
rZcmdtableZcommandZconfigtableZ
configitemZ
testedwithr:ZwalkoptsZ
commitoptsZcommitopts2Zcommitopts3ZCATEGORY_CHANGE_MANAGEMENTr[r\rjrrrr�<module>sd4

��
�
@��
���
��
g�

Youez - 2016 - github.com/yon3zu
LinuXploit