Repository URL to install this package:
| 
      
        
        
        Version: 
        
         
          
          0.1.31-1  ▾
        
         | 
| 
    
    odigos-demo-inventory
  
    /
        
    opt
  
        /
        
    odigos-demo-inventory
  
        /
        
    site-packages
  
        /
        
    dulwich
  
        /
        
    __pycache__
  
        /
        patch.cpython-311.pyc
   | 
|---|
§
    iµµh'1  ã                   óø    d Z ddlZddlZddlmZ ddlmZmZm	Z	m
Z
 ddlmZm
Z
mZ ddlmZ dZdd	Zd
 Zd Z	 	 	 	 	 	 	 	 ddZd Zd Zd Zd defdZd Zd Zd dZd!de
e	ef         dee         fdZd!dZdS )"z~Classes for dealing with git am-style patches.
These patches are basically unified diffs with some extra metadata tacked
on.
é    N)ÚSequenceMatcher)ÚBinaryIOÚOptionalÚTextIOÚUnioné   )ÚS_ISGITLINKÚBlobÚCommit)ÚObjectContaineri@  c                 ó    |pt          | dd¦  «        }t          |t          ¦  «        r|                     |¦  «        }|\  }}|                      d|j        z   dz   t
          j        |j        ¦  «                             |¦  «        z   dz   ¦  «         |                      d|j	        z   dz   ¦  «         |                      dt
          j
        d¦  «                             |¦  «        z   dz   ¦  «         |                      d	||fz                       |¦  «        |j        z   dz   ¦  «         |                      d¦  «         |                      d
¦  «         	 ddl}| 
                    d
g|j        |j        ¬¦  «        }	|	                     |¦  «        \  }
}|                      |
¦  «         |                      d¦  «         n# t           t"          f$ r Y nw xY w|                      |¦  «         |                      d¦  «         | ddlm} |                      d|z  ¦  «         dS |                      |                     |¦  «        dz   ¦  «         dS )zºWrite a individual file patch.
    Args:
      commit: Commit object
      progress: Tuple with current patch number and total.
    Returns:
      tuple with filename and contents
    ÚencodingÚasciis   From ó    ó   
ó   From: s   Date: z%a, %d %b %Y %H:%M:%S %ZzSubject: [PATCH %d/%d] ó   ---
r   NÚdiffstat)ÚstdoutÚstdinó   -- 
)Ú__version__s   Dulwich %d.%d.%d
)ÚgetattrÚ
isinstanceÚstrÚencodeÚwriteÚidÚtimeÚctimeÚcommit_timeÚauthorÚstrftimeÚmessageÚ
subprocessÚPopenÚPIPEÚcommunicateÚImportErrorÚOSErrorÚdulwichr   )
ÚfÚcommitÚcontentsÚprogressÚversionr   ÚnumÚtotalr%   Úpr   Ú_Údulwich_versions
                ú8/usr/local/lib/python3.11/site-packages/dulwich/patch.pyÚwrite_commit_patchr7   &