Skip to main content

File System Tree

Project description

python-immutable-fs-trees

github action status

Install

pip install hexlet-immutable-fs-trees

Usage example

>>> import hexlet.fs as fs
>>> fs.is_file(fs.mkfile('config'))
True
>>> fs.is_directory(fs.mkdir('etc'))
True
>>> tree = fs.mkdir('etc', [fs.mkfile('config'), fs.mkfile('hosts')])
>>> children = fs.get_children(tree)
>>> fs.get_name(children[0])
'config'
>>> list(map(lambda item: fs.get_name(item), children))
['config', 'hosts']
>>>

Hexlet Ltd. logo

This repository is created and maintained by the team and the community of Hexlet, an educational project. Read more about Hexlet (in Russian).

See most active contributers on hexlet-friends.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

hexlet-immutable-fs-trees-0.1.8.tar.gz (2.7 kB view hashes)

Uploaded Source

Built Distribution

hexlet_immutable_fs_trees-0.1.8-py3-none-any.whl (2.8 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page