Created
January 23, 2013 16:50
-
-
Save ptrin/4609708 to your computer and use it in GitHub Desktop.
Revisions
-
ptrin renamed this gist
Jan 23, 2013 . 1 changed file with 0 additions and 0 deletions.There are no files selected for viewing
File renamed without changes. -
ptrin created this gist
Jan 23, 2013 .There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,17 @@ def get_file_list(dir=options.source_dir): """ Returns list of all html files in specified directory (recursive) """ fileList = [] print dir try: for root, subFolders, files in os.walk(dir): for file in files: filepath = os.path.join(root,file) if ".html" in filepath: fileList.append(filepath) print fileList return fileList except OSError as e: print e.errno print e.filename print e.strerror