#NEWLINE# def walk_get_gitignore( base_path ) : #NEWLINE# #INDENT# 'Use os.walk to get all `.gitignore` under base_path\n\n    :param base_path: str -- the path to deal with\n    :return: list of str -- the path of all `.gitignore`\n    ' #NEWLINE# base_path = os . path . abspath ( base_path ) #NEWLINE# result = [ ] #NEWLINE# for ( root_path , dirs_path , files_path ) in os . walk ( base_path ) : #NEWLINE# #INDENT# for _file_path in files_path : #NEWLINE# #INDENT# if ( _file_path == '.gitignore' ) : #NEWLINE# #INDENT# file_path = os . path . join ( root_path , _file_path ) #NEWLINE# abs_file_path = os . path . abspath ( file_path ) #NEWLINE# result . append ( abs_file_path ) #NEWLINE# #UNINDENT# #UNINDENT# #UNINDENT# return result