{ "info": { "author": "Bagrat Aznauryan", "author_email": "bagrat@aznauryan.org", "bugtrack_url": null, "classifiers": [ "Intended Audience :: Developers", "License :: OSI Approved :: MIT License", "Natural Language :: English", "Operating System :: MacOS", "Operating System :: Microsoft :: Windows", "Operating System :: POSIX", "Operating System :: POSIX :: Linux", "Programming Language :: Python", "Programming Language :: Python :: 2", "Programming Language :: Python :: 3", "Topic :: Software Development :: Libraries :: Python Modules" ], "description": "Pyerarchy\n=========\n\nPyerarchy is a Python package for easy file system surfing and manipulation. It enables to interact with the file system\ndirectly as Python objects without making implicit calls to ``os`` package. Finally it makes the code much more readable\nand nice.\n\n\nBasic Usage\n-----------\n\nThe central point of Pyerarchy is the Node. The basic usage starts by initializing an entry point Node and manipulating\nit further::\n\n node = Node('entry/point/path') # Initialize a new node\n\n children = node.ls() # List all child entities of the node\n node.mkdir('newdir').mkdir('anotherdir') # Create a new directory under node, and another one under the new one :)\n\n # Now access the newly created directories\n anotherdir = node/'newdir'/'anotherdir' # This is the most common way to access nodes\n children = node.newdir.anotherdir.ls() # This method can be used to invoke an operation on the result node\n\n # What about files?\n myfile = node.myfile\n\n # And even...\n myfile = node.myfile.open('w')\n\n # Or...\n contents = node.myfile.read() # ...which handles everything\n\n # What if the filename contains a dot, dash, etc?\n # Well...\n myfile_node = node/'filename.with.dots-and-dashes'\n\n # And then do your stuff on myfile_node\n with myfile_node.open('r') as f:\n ...\n\n # Or again...\n contents = myfile_node.read()\n\nAnother useful feature of Pyerarchy is very handy in Python modules to interact with static files included in the module::\n\n static_data_node = ThisModuleNode()/'path/to/the/static/data/relative/to/module'\n\n some_file_node = static_data_node/'some/static/text/file'\n\n contents = some_file_node.read()\n\n", "description_content_type": null, "docs_url": null, "download_url": "git@github.com:n9code/pyerarchy.git", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "git@github.com:n9code/pyerarchy.git", "keywords": "directory file object", "license": "MIT", "maintainer": null, "maintainer_email": null, "name": "pyerarchy", "package_url": "https://pypi.org/project/pyerarchy/", "platform": "UNKNOWN", "project_url": "https://pypi.org/project/pyerarchy/", "project_urls": { "Download": "git@github.com:n9code/pyerarchy.git", "Homepage": "git@github.com:n9code/pyerarchy.git" }, "release_url": "https://pypi.org/project/pyerarchy/0.1/", "requires_dist": null, "requires_python": null, "summary": "Access directories like objects", "version": "0.1" }, "last_serial": 1379064, "releases": { "0.0": [ { "comment_text": "", "digests": { "md5": "bfa05c24ac789a6adadfeadd6eeb4c5b", "sha256": "5cc2e0a5f9f0b2e2d74b3375050d7a5ed04167925e8017e4fce3df78fa403a61" }, "downloads": -1, "filename": "pyerarchy-0.0.tar.gz", "has_sig": false, "md5_digest": "bfa05c24ac789a6adadfeadd6eeb4c5b", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 4255, "upload_time": "2015-01-11T16:54:42", "url": "https://files.pythonhosted.org/packages/da/d4/dabc41474e219fe80b574a9454f1dbae0eedd8c8e6ad055d54cea6f5bf92/pyerarchy-0.0.tar.gz" } ], "0.1": [ { "comment_text": "", "digests": { "md5": "cbb6970b529372dbbc035526955d6034", "sha256": "3b6a8a386908c7a6317c62bd828502032a62e5fd3b89cf4c2d6d3bd2a0292600" }, "downloads": -1, "filename": "pyerarchy-0.1.tar.gz", "has_sig": false, "md5_digest": "cbb6970b529372dbbc035526955d6034", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 5168, "upload_time": "2015-01-12T06:18:23", "url": "https://files.pythonhosted.org/packages/11/85/589cae03e63cb2fd19bf975b07da36012e6389ba23306d608795dc72eefa/pyerarchy-0.1.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "cbb6970b529372dbbc035526955d6034", "sha256": "3b6a8a386908c7a6317c62bd828502032a62e5fd3b89cf4c2d6d3bd2a0292600" }, "downloads": -1, "filename": "pyerarchy-0.1.tar.gz", "has_sig": false, "md5_digest": "cbb6970b529372dbbc035526955d6034", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 5168, "upload_time": "2015-01-12T06:18:23", "url": "https://files.pythonhosted.org/packages/11/85/589cae03e63cb2fd19bf975b07da36012e6389ba23306d608795dc72eefa/pyerarchy-0.1.tar.gz" } ] }