skip to navigation
skip to content

dirpath 0.0.34

dirpath(path) function - get path directory

.. README generated with readmemako.py (github.com/russianidiot/readme-mako.py) and .README dotfiles (github.com/russianidiot-dotfiles/.README)
.. image:: https://img.shields.io/badge/Language-Python-blue.svg?style=plastic
:target: none
.. image:: https://img.shields.io/pypi/pyversions/dirpath.svg
:target: https://pypi.org/pypi/dirpath
.. image:: https://img.shields.io/pypi/v/dirpath.svg
:target: https://pypi.org/pypi/dirpath
|
.. image:: https://api.codacy.com/project/badge/Grade/a4a0951f796e45129f75a0399e7c3b8a
:target: https://www.codacy.com/app/russianidiot/dirpath-py
.. image:: https://codeclimate.com/github/russianidiot/dirpath.py/badges/gpa.svg
:target: https://codeclimate.com/github/russianidiot/dirpath.py
.. image:: https://landscape.io/github/russianidiot/dirpath.py/master/landscape.svg?style=flat
:target: https://landscape.io/github/russianidiot/dirpath.py
.. image:: https://scrutinizer-ci.com/g/russianidiot/dirpath.py/badges/quality-score.png?b=master
:target: https://scrutinizer-ci.com/g/russianidiot/dirpath.py/
|
.. image:: https://scrutinizer-ci.com/g/russianidiot/dirpath.py/badges/build.png?b=master
:target: https://scrutinizer-ci.com/g/russianidiot/dirpath.py/
.. image:: https://semaphoreci.com/api/v1/russianidiot/dirpath-py/branches/master/badge.svg
:target: https://semaphoreci.com/russianidiot/dirpath-py
.. image:: https://api.travis-ci.org/russianidiot/dirpath.py.svg?branch=master
:target: https://travis-ci.org/russianidiot/dirpath.py/
.. image:: https://app.wercker.com/status/7baea52d25d473089a7609d02d0c7cf5/s/master
:target: https://app.wercker.com/russianidiot/dirpath.py
Install
```````
.. code:: bash
`[sudo] pip install dirpath`
Usage
`````
.. code:: python
>>> print(__file__)
'path/to/this/file'
>>> print(dirpath(__file__))
'path/to/this'
>>> import os
>>> print(dirpath(os.path.dirname(__file__)))
'path/to/this'
Examples
````````
.. code:: python
>>> from dirpath import *
>>> dirpath(path)
Feedback |github_follow| |github_issues|
.. |github_follow| image:: https://img.shields.io/github/followers/russianidiot.svg?style=social&label=Follow
:target: https://github.com/russianidiot
.. |github_issues| image:: https://img.shields.io/github/issues/russianidiot/dirpath.py.svg
:target: https://github.com/russianidiot/dirpath.py/issues  
File Type Py Version Uploaded on Size
dirpath-0.0.34.tar.gz (md5) Source 2017-12-07 2KB