<s> import os <EOL> def dashify ( string ) : <EOL> return string . replace ( '<STR_LIT:_>' , '<STR_LIT:->' ) <EOL> def touch ( filename ) : <EOL> fp = open ( filename , '<STR_LIT:a>' ) <EOL> fp . close ( ) <EOL> def is_git_dir ( d ) : <EOL> """<STR_LIT>""" <EOL> if os . path . isdir ( d ) and os . path . isdir ( os . path . join ( d , '<STR_LIT>' ) ) and os . path . isdir ( os . path . join ( d , '<STR_LIT>' ) ) : <EOL> headref = os . path . join ( d , '<STR_LIT>' ) <EOL> return os . path . isfile ( headref ) or ( os . path . islink ( headref ) and <EOL> os . readlink ( headref ) . startswith ( '<STR_LIT>' ) ) <EOL> return False </s>
