{ Snipperize } /directory

Snippets about directory

Here are the latest snippets talking about directory. Please choose your favorite one or add a new one.

Global Directory Walker

for file in GlobDirectoryWalker(".", "*.py"): print file

Python / directory, fnmatch, os, walker, recursive / by ThePeppersStudio (108 days, 5.39 hours ago)

Recursively list all files and directories below a given directory

This is example code of how to walk a directory recurisively and create a flat list of fully qualified names for all the files and directories under the supplied virtual root directory.

Objective-C / file, directory, list / by ThePeppersStudio (118 days, 7.72 hours ago)

Super File System Service

The one and only class for all your file handling needs. Browse a directory and all child directories: $filesSvc = new FileSystemService ( ); $templates = $filesSvc->browseDirectory ( '../path/to/directory', true ); echo jsonencode ( $templates ); printr( $templates ); Read a file: $file = FileSystemService::readFile ( '/path/to/file.html' ); echo ( $file ); Write a file: $file = FileSystemService::writeFile ( 'FileName', 'Is this enough information Vordreller? I think you should try to experiment.' );

PHP / file, directory, handler / by ThePeppersStudio (200 days, 13.82 hours ago)

Make directory if it doesn't already exist

Python / directory, mkdir, os / by ThePeppersStudio (234 days, 3.50 hours ago)

  • 1