Skip to main content

Code parser tool

Project description


PyPI version PyPI pyversions PyPI license readthedocs

Code parsing command line tool.


With pip via PyPi

pip install cparse

Clone the repository and install

git clone git://
cd cparse
python install


Full documentation can be found here

cparse currently includes 6 commands

  • ls - list files in directory
  • tree - print file tree
  • stat - directory file extension stats
  • py - python code parsing
  • html - html link parsing
  • css - css code parsing


Prints a list of the files in a directory.

cparse ls [-r] [-n <depth>] [-d | -f] [-a] [-lim <count>] [-fmt <format>]
          [-exc <path>] [-inc <path>]
          [-wc <pattern>] [-grep <regexp>] [-ft <filetype>]
          [-m | -M | -c | -C | -b | -B | -i | -I | -g | -G] <path>


Prints a tree representation of the contents of a directory.

cparse tree [-d | -f] [-a] [-n <depth>] [-fmt <format>]
            [-exc <path>] [-inc <path>]
            [-wc <pattern>] [-grep <regular-expression>] [-ft <file-extension>]
            [-m | -M | -c | -C | -b | -B | -i | -I | -g | -G] <path>


Prints a table displaying the file extension proportions of a directory

cparse stat [-a] <path>


Parses the code of a provided python file

cparse py <path>


Parses the links in an HTML file and represents them as a file tree.

cparse html <path>


Parses CSS code, providing options to condense redundant rules and group identical selectors.

cparse css [-g] [-c] [-s] <path>


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

cparse-0.0.2.tar.gz (21.6 kB view hashes)

Uploaded Source

Built Distribution

cparse-0.0.2-py3-none-any.whl (34.4 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