{ "info": { "author": "Hai Vu", "author_email": "haivu2004@gmail.com", "bugtrack_url": null, "classifiers": [ "Development Status :: 5 - Production/Stable", "Environment :: Console", "Intended Audience :: Developers", "License :: OSI Approved :: BSD License", "Operating System :: OS Independent", "Programming Language :: Python", "Topic :: Software Development :: Libraries :: Python Modules", "Topic :: Utilities" ], "description": "files_finder -- Find files recursively\r\n========================================\r\n\r\n\r\nIntroduction\r\n------------\r\n\r\nThis package implements the `FilesFinder` class to simplify finding files\r\nrecursively from a specified directory. This class is easier to use, yet more\r\npowerful than `os.walk`.\r\n\r\nExamples\r\n--------\r\n\r\nBelow is a few examples, for more ways to use `FilesFinder`, see the\r\nsamples directory.\r\n\r\nFind all files:\r\n\r\n from files_finder import FilesFinder\r\n for filename in FilesFinder('.'):\r\n print(filename)\r\n\r\nExclude a single pattern:\r\n\r\n from files_finder import FilesFinder, wildcard\r\n for filename in FilesFinder('.', exclude=wildcard('*.bak')):\r\n print(filename)\r\n\r\nExclude more than one patterns:\r\n\r\n from files_finder import FilesFinder, wildcard\r\n for filename in FilesFinder('.', exclude=wildcard('*.bak', '*~')):\r\n print(filename)\r\n\r\nOnly include files that match some patterns:\r\n\r\n from files_finder import FilesFinder, wildcard\r\n for filename in FilesFinder('.', include=wildcard('*.csv', '*.xml')):\r\n print(filename)\r\n\r\n\r\nFilesFinder Object\r\n------------------\r\n\r\n FilesFinder(root, exclude=None, include=None, recurse=True)\r\n\r\nCreates a new `FilesFinder` object. The caller can loop\r\nthrough the object to gain access to all the files found in the\r\n`root` directory. See the Examples section.\r\n\r\n`root` is a string representing the directory to search for files.\r\n\r\n`exclude` is a function which takes in a path and returns a boolean\r\nindicating if that path should be excluded from the results. The\r\ndefault is None which means do not exclude any file. Note that the\r\n`exclude` parameter has precedence over the `include` parameter.\r\n\r\n`include` is a function which takes in a path and returns a boolean\r\nindicating if that path should be included in the results.\r\n\r\n`recurse` is a boolean indicating if `FilesFinder` should\r\nsearch recursively. The default is True.", "description_content_type": null, "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "", "keywords": "", "license": "OSI Approved\r\nBSD License", "maintainer": "Hai Vu", "maintainer_email": "haivu2004@gmail.com", "name": "files_finder", "package_url": "https://pypi.org/project/files_finder/", "platform": "", "project_url": "https://pypi.org/project/files_finder/", "project_urls": null, "release_url": "https://pypi.org/project/files_finder/1.0/", "requires_dist": null, "requires_python": null, "summary": "", "version": "1.0" }, "last_serial": 1522047, "releases": { "1.0": [] }, "urls": [] }