Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/schrodingdong/deraph
Simple CLI to generate graphviz graphs of your python project's dependencies.
https://github.com/schrodingdong/deraph
dependency-graph golang graphviz parsing python
Last synced: 1 day ago
JSON representation
Simple CLI to generate graphviz graphs of your python project's dependencies.
- Host: GitHub
- URL: https://github.com/schrodingdong/deraph
- Owner: Schrodingdong
- Created: 2024-11-25T02:59:43.000Z (2 months ago)
- Default Branch: main
- Last Pushed: 2024-11-30T18:37:26.000Z (2 months ago)
- Last Synced: 2024-12-05T00:09:31.099Z (about 2 months ago)
- Topics: dependency-graph, golang, graphviz, parsing, python
- Language: Go
- Homepage:
- Size: 79.1 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# DERAPH
Simple CLI to generate graphviz graphs of your python project's dependencies.## Quickstart
- Run the following commands:
- Download the binary for your OS/ARCH
- Unzip it
- Give it execution permissions
- Move it to a dir included in $PATH
```bash
wget "https://github.com/Schrodingdong/Deraph/releases/download/1.0.0/deraph-(OS)-(ARCH).zip"
unzip deraph-OS-ARCH.zip
chmod 777 deraph-linux-amd64
sudo mv deraph-linux-amd64 /usr/local/bin/deraph # Or any dir, just make the dir path is included in the $PATH variable
```- That's it ! to run your program:
```bash
deraph
# Usage template:
# deraph [-ext] [-v] --path [--out ]
```- To generate the image graph, you can use the [dot](https://graphviz.org/download/) command
```bash
dot -Tpng path/to/outFileName -o imageName.png
```## From source code
- Clone the project
- Build the program
```bash
go build .
```- To use the cli:
```
./deraph [-ext] [-v] --path [--out ]
```## Example
```bash
deraph --path ./example/python_project # output: $(your_cwd)/graphviz.gv
deraph --ext --path ./example/python_project # Includes external dependencies
deraph --ext -v --path ./example/python_project # verbose output
deraph --ext -v --path ./example/python_project --out superdupercoolgraph.gv
```- Here is the image output
![Project dependency graph](images/pyproject_graph.png "Project dependency graph")
- And here with external dependencies shown
![Project dependency graph with external dependencies shown](images/ext_dep_pyproject_graph.png "Project dependency graph with external dependencies shown")