Viewing File: /opt/alt/python35/lib/python3.5/site-packages/humanize/__pycache__/filesize.cpython-35.opt-1.pyc



S@s7dZddd
dddiZdddddZdS)z"Bits & Bytes related humanization.decimalkBMBGBTBPBEBZBYBbinaryKiBMiBGiBTiBPiBEiBZiBYiBgnuZKMGTPEZYFz%.1fc
Cs^|rtd}n|r&td}n
td}|s<|rBdnd}t|}|dkrk|rkdS||kr|rd|S||kr|rd	|Sxt|D]s\}}||d
}	||	kr|r|d|||	|fS||	kr|r|d|||	|fSqW|rD|d|||	|fS|d|||	|fS)
aFormat a number of byteslike a human readable filesize (eg. 10 kB).  By
    default, decimal suffixes (kB, MB) are used.  Passing binary=true will use
    binary suffixes (KiB, MiB) are used and the base will be 2**10 instead of
    10**3.  If ``gnu`` is True, the binary argument is ignored and GNU-style
    (ls -sh style) prefixes are used (K, M) with the 2**10 definition.
    Non-gnu modes are compatible with jinja2's ``filesizeformat`` filter.rr
riiz1 Bytez%d Bytesz%dBz %sz%s)suffixesfloat	enumerate)
valuer
rformatsuffixbasebytesisZunitr /filesize.pynaturalsizes,


r"N)rrrrrrrr	)rrr
rrrrr)__doc__rr"r r r r!<module>s
Back to Directory File Manager