File manager - Edit - /opt/saltstack/salt/lib/python3.10/site-packages/jaraco/text/__pycache__/show-newlines.cpython-310.pyc
Back
o ;j � @ sV d dl mZ d dlZd dlZd dlmZ d dlZddd �Ze d ko(e� e� dS dS )� )�annotationsN)�always_iterable�input�typer.FileText�return�Nonec C sH t j�| �}ttt|���}t�� }t|� d|�|� d|�t|�� dS )a� Report the newlines in the indicated file. >>> tmp_path = getfixture('tmp_path') >>> filename = tmp_path / 'out.txt' >>> _ = filename.write_text('foo\nbar\n', newline='', encoding='utf-8') >>> report_newlines(filename) newline is '\n' >>> filename = tmp_path / 'out.txt' >>> _ = filename.write_text('foo\nbar\r\n', newline='', encoding='utf-8') >>> report_newlines(filename) newlines are ('\n', '\r\n') �newline�isN)�jaraco�textZ read_newlines�len�tupler �inflect�engine�printZplural_nounZplural_verb�repr)r �newlines�countr � r �M/opt/saltstack/salt/lib/python3.10/site-packages/jaraco/text/show-newlines.py�report_newlines s �r �__main__)r r r r )� __future__r r ZtyperZmore_itertoolsr Zjaraco.textr r �__name__�runr r r r �<module> s
| ver. 1.4 |
Github
|
.
| PHP 8.2.30 | Generation time: 0 |
proxy
|
phpinfo
|
Settings