| Server IP : 108.167.183.253 / Your IP : 216.73.216.79 Web Server : Apache System : Linux gator4209.hostgator.com 5.14.0-687.39.1.el9_8.x86_64 #1 SMP PREEMPT_DYNAMIC Tue Aug 18 06:09:16 EDT 2026 x86_64 User : raghunath ( 2558) PHP Version : 8.3.33 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : ON | Pkexec : ON Directory : /lib64/python3.9/site-packages/hgext/largefiles/__pycache__/ |
Upload File : |
a
�+�b�e � @ sH d Z ddlmZ ddlZddlZddlZddlZddlmZ ddl m
Z
ddlmZ ddl
mZmZmZmZmZmZmZmZmZmZmZ ddlmZ dd lmZ d
Zed Z dZ!ej"dhdd��Z#didd�Z$dd� Z%dd� Z&e!fdd�Z'dd� Z(dd� Z)G dd� dej�Z*djdd �Z+d!d"� Z,dkd#d$�Z-dld&d'�Z.dmd(d)�Z/d*d+� Z0d,d-� Z1d.d/� Z2d0d1� Z3d2d3� Z4d4d5� Z5dnd6d7�Z6d8d9� Z7d:d;� Z8d<d=� Z9d>d?� Z:d@dA� Z;dBdC� Z<dDdE� Z=dFdG� Z>dHdI� Z?dJdK� Z@dLdM� ZAdNdO� ZBdPdQ� ZCdRdS� ZDdTdU� ZEG dVdW� dWeF�ZGdXdY� ZHdZd[� ZId\d]� ZJd^d_� ZKd`da� ZLdbdc� ZMG ddde� deeN�ZOdodfdg�ZPdS )pzGlargefiles utility code: must not import other modules in this package.� )�absolute_importN)�_)�hex)�open)�dirstate�encoding�error�httpconnection�match�pycompat�requirements�scmutil�sparse�util�vfs)�hashutil)� timestamps .hglf� /�
largefilesTc c s0 t | dd�}|| _zd V W || _n|| _0 d S )N�lfstatusF)�getattrr )�repo�valueZoldvalue� r �=/usr/lib64/python3.9/site-packages/hgext/largefiles/lfutil.pyr , s
r �
c C sl |}|s|r| j td|d�}|rRzt|�}W n$ tyP t�td�| ��Y n0 |d u rht�td���|S )Ns minsize)�defaults) largefiles: size must be number (not %s)
s- minimum size for largefiles must be specified)Zconfig�longname�float�
ValueErrorr �Abortr )�uiZassumelfiles�optr Zlfsizer r r �
getminsize6 s
�
r# c C s� t �tj�|�� zt �| |� W n� ty� t| d��T}t �|��*}t � |�D ]}|�
|� qRW d � n1 sv0 Y W d � n1 s�0 Y t�|t�| �j
� Y n0 dS )z@Try to create hardlink - if that fails, efficiently make a copy.� rbN)r �makedirs�os�path�dirnameZoslink�OSErrorr �atomictempfile�
filechunkiter�write�chmod�stat�st_mode)�src�dest�srcf�dstf�chunkr r r �linkF s Hr5 c C s t j�t| �|�S )z�Return the correct location in the "global" largefiles cache for a file
with the given hash.
This cache is used for sharing of largefiles across repositories - both
to preserve download bandwidth and storage space.)r&