
    6              
          S r SSKJr  SSKJr  SSKJr  SSKJr  SSKrSSKrSSKrSSK	r	SSK
rSSKJr  \" 5       u  rr\(       d  \R                   R#                  \5      e\R$                  " SS5      r\(       a?   SSKr\R(                  " \S	S	S
/SS\	R*                  " 5       S-   /S9r\R/                  5         \R2                  R5                  \R2                  R7                  \5      5      r\R2                  R7                  \R<                  S   5      r\R2                  R5                  \5      r S	r!Sr"\r#\R2                  RI                  \R2                  RK                  \#S5      5      (       d%  \R2                  RM                  \ \45      \ :X  a  Sr!\ r#\R2                  RI                  \R2                  RK                  \#S5      5      (       d7  \R2                  RO                  \R2                  RK                  \S5      5      r#S	r"Sr(S r)\)" 5         S r*\*" S5      u  r+r,\,(       d  \R                   R#                  S5      e\,r-\*" S5      u  r.r/\/(       d  \R                   R#                  S5      eS r0g! \ a     GNf = f)zPackage marker file.    )absolute_import)division)print_function)unicode_literalsN)check_python_version_supportGSUTIL_COVERAGE_OUTPUT_FILETgslibzgslib/third_party/*zgslib/tests/**)	data_filedata_suffix	auto_datasourceomitFVERSIONz.. c            	      f   [         R                  R                  [        S5      n SS/nU HC  u  p#[        R                  R                  S[         R                  R                  XU5      5        ME     [        R                  R                  [         R                  R                  U SSSS5      5        g	)
zFFix our Python path so that it correctly finds our vendored libraries.vendored)botor   )oauth2clientr   r   r   testsintegrations3N)ospathjoin	GSLIB_DIRsysinsertappend)vendored_pathvendored_lib_dirslibdirsubdirs       !platform/gsutil/gslib/__init__.py_AddVendoredDepsToPythonPathr%   `   s    '',,y*5-  *nfHHOOArww||M6BC * ((//ggll=&'=$GI    c                    [         R                  R                  [        U 5      n[         R                  R	                  U5      (       a&  [        US5       nUR                  5       nSSS5        O[        R                  " SU 5      nSnWbT  [        R                  R                  S:  a&  [        U[        5      (       a  UR                  S5      nUR                  5       nX4$ ! , (       d  f       Nh= f)a   Tries to find the given filename on disk or via pkgutil.get_data.

Args:
  filename: String name of the file.

Returns:
  A tuple containing the absolute path to the requested file and the file's
  contents as a string (or None if the file doesn't exist).
rNr	      zutf-8)r   r   r   PROGRAM_FILES_DIRisfileopenreadpkgutilget_datar   version_infomajor
isinstancebytesdecodestrip)filenamefpathfcontents       r$   _GetFileContentsr:   |   s     '',,((
3%WW^^E	eS	Qg 
	 w1GE
!j%&@&@w'gmmoG
	 
	s   C""
C0z<VERSION file not found. Please reinstall gsutil from scratchCHECKSUMz=CHECKSUM file not found. Please reinstall gsutil from scratchc                  r    [         (       d  g[        [        R                  R	                  [         5      5      $ )zBReturns unix timestamp of when the VERSION file was last modified.r   )VERSION_FILEintr   r   getmtime r&   r$   GetGsutilVersionModifiedTimerA      s$    		RWWl+	,,r&   )1__doc__
__future__r   r   r   r   r   r.   r   tempfilegslib.exceptionr	   gslib.utils.version_checkr   	supportederr	exceptionCommandExceptiongetenvcoverage_outfilecoverage
gettempdircoverage_controllerstartImportErrorr   dirnamerealpath__file__r   argvGSUTIL_PATH
GSUTIL_DIRIS_PACKAGE_INSTALLIS_EDITABLE_INSTALLr*   r+   r   commonprefixnormpath
USER_AGENTr%   r:   r=   r   __version__CHECKSUM_FILEr;   rA   r@   r&   r$   <module>r_      sP  ,  &  % ' 	  
   B-/	3((--99:DA 	"++6F8<6:4;90E0?080C0C0E0K2.	/ 
 GGOOBGG,,X67	ggsxx{+WW__[)

    
   	rww||$5yABBGG*i01Z?  
ww~~bggll#4i@AAgg&&rww||It'DE 
I2  2 )3 g((D	F F +:6 x((E	G G-W 
 		s   <>I6 6J ?J 