File: //proc/self/root/opt/alt/python27/lib64/python2.7/site-packages/numpy/distutils/line_endings.pyc
�
�9Zc @` s� d Z d d l m Z m Z m Z d d l Z d d l Z d d l Z d � Z d � Z d � Z
d � Z d � Z d � Z
e d
k r� e
e j d � n d S( s9 Functions for converting from DOS to UNIX line endings
i ( t divisiont absolute_importt print_functionNc C` s� t j j | � r# t | d � d St | d � j � } d | k rU t | d � d St j d d | � } | | k r� t d | � t | d � } | j | � | j � | St | d
� d S( sF Replace CRLF with LF in argument files. Print names of changed files.s
Directory!Nt rbs s Binary!s
s
s dos2unix:t wbt ok(
t ost patht isdirt printt opent readt ret subt writet close( t filet datat newdatat f( ( sO /opt/alt/python27/lib64/python2.7/site-packages/numpy/distutils/line_endings.pyt dos2unix s
c C` sR xK | D]C } t j j | | � } t | � } | d k r | j | � q q Wd S( N( R R t joinR t Nonet append( t modified_filest dir_namet
file_namesR t full_path( ( sO /opt/alt/python27/lib64/python2.7/site-packages/numpy/distutils/line_endings.pyt dos2unix_one_dir s
c C` s g } t j j | t | � | S( N( R R t walkR ( R R ( ( sO /opt/alt/python27/lib64/python2.7/site-packages/numpy/distutils/line_endings.pyt dos2unix_dir$ s c C` s� t j j | � r# t | d � d St | d � j � } d | k rU t | d � d St j d d | � } t j d d | � } | | k r� t d | � t | d � } | j | � | j � | St | d
� d S( sF Replace LF with CRLF in argument files. Print names of changed files.s
Directory!NR s s Binary!s
s
s unix2dos:R R (
R R R R R
R R R
R R ( R R R R ( ( sO /opt/alt/python27/lib64/python2.7/site-packages/numpy/distutils/line_endings.pyt unix2dos* s
c C` sP xI | D]A } t j j | | � } t | � | d k r | j | � q q Wd S( N( R R R R R R ( R R R R R ( ( sO /opt/alt/python27/lib64/python2.7/site-packages/numpy/distutils/line_endings.pyt unix2dos_one_dir? s
c C` s g } t j j | t | � | S( N( R R R R ( R R ( ( sO /opt/alt/python27/lib64/python2.7/site-packages/numpy/distutils/line_endings.pyt unix2dos_dirF s t __main__i ( t __doc__t
__future__R R R t sysR R R R R R R R! t __name__t argv( ( ( sO /opt/alt/python27/lib64/python2.7/site-packages/numpy/distutils/line_endings.pyt <module> s $