This is a pre-production deployment of Warehouse, however changes made here WILL affect the production instance of PyPI.
Latest Version Dependencies status unknown Test status unknown Test coverage unknown
Project Description

Pyerarchy is a Python package for easy file system surfing and manipulation. It enables to interact with the file system directly as Python objects without making implicit calls to os package. Finally it makes the code much more readable and nice.

Basic Usage

The central point of Pyerarchy is the Node. The basic usage starts by initializing an entry point Node and manipulating it further:

node = Node('entry/point/path')  # Initialize a new node

children = node.ls()  # List all child entities of the node
node.mkdir('newdir').mkdir('anotherdir')  # Create a new directory under node, and another one under the new one :)

# Now access the newly created directories
anotherdir = node/'newdir'/'anotherdir'  # This is the most common way to access nodes
children = node.newdir.anotherdir.ls()  # This method can be used to invoke an operation on the result node

# What about files?
myfile = node.myfile

# And even...
myfile = node.myfile.open('w')

# Or...
contents = node.myfile.read()  # ...which handles everything

# What if the filename contains a dot, dash, etc?
# Well...
myfile_node = node/'filename.with.dots-and-dashes'

# And then do your stuff on myfile_node
with myfile_node.open('r') as f:
    ...

# Or again...
contents = myfile_node.read()

Another useful feature of Pyerarchy is very handy in Python modules to interact with static files included in the module:

static_data_node = ThisModuleNode()/'path/to/the/static/data/relative/to/module'

some_file_node = static_data_node/'some/static/text/file'

contents = some_file_node.read()
Release History

Release History

0.1

This version

History Node

TODO: Figure out how to actually get changelog content.

Changelog content for this version goes here.

Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur. Donec ut libero sed arcu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

Show More

0.0

History Node

TODO: Figure out how to actually get changelog content.

Changelog content for this version goes here.

Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur. Donec ut libero sed arcu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

Show More

Download Files

Download Files

TODO: Brief introduction on what you do with files - including link to relevant help section.

File Name & Checksum SHA256 Checksum Help Version File Type Upload Date
pyerarchy-0.1.tar.gz (5.2 kB) Copy SHA256 Checksum SHA256 Source Jan 12, 2015

Supported By

WebFaction WebFaction Technical Writing Elastic Elastic Search Pingdom Pingdom Monitoring Dyn Dyn DNS HPE HPE Development Sentry Sentry Error Logging CloudAMQP CloudAMQP RabbitMQ Heroku Heroku PaaS Kabu Creative Kabu Creative UX & Design Fastly Fastly CDN DigiCert DigiCert EV Certificate Rackspace Rackspace Cloud Servers DreamHost DreamHost Log Hosting