https://github.com/reugn/pyloc
Python implementation of tool for counting lines of code
https://github.com/reugn/pyloc
cloc codelines lines-of-code python
Last synced: about 1 year ago
JSON representation
Python implementation of tool for counting lines of code
- Host: GitHub
- URL: https://github.com/reugn/pyloc
- Owner: reugn
- License: gpl-3.0
- Created: 2019-03-02T09:38:10.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2019-03-07T17:08:28.000Z (about 7 years ago)
- Last Synced: 2025-01-17T03:25:53.138Z (over 1 year ago)
- Topics: cloc, codelines, lines-of-code, python
- Language: Python
- Size: 30.3 KB
- Stars: 2
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
## pyloc
[]()
Python implementation of tool for counting lines of code.
### Installation
```
pip install -U git+https://github.com/reugn/pyloc.git
```
### Usage
pyloc --help
```
usage: pyloc [options]
positional arguments:
path working directory
optional arguments:
-h, --help show this help message and exit
-gi, --gitignore filter sources by .gitignore file
-s {files,comment,code,blank}, --sort {files,comment,code,blank}
sort results by field
-o {table,json}, --out {table,json}
output format
```
Simple example
```
pyloc ./test
+------------+---------+-----------+--------+---------+
| File Ext | Files | Comment | Code | Blank |
+============+=========+===========+========+=========+
| py | 2 | 104 | 111 | 55 |
+------------+---------+-----------+--------+---------+
| c | 1 | 24 | 70 | 21 |
+------------+---------+-----------+--------+---------+
```