An interactive terminal UI for navigating your Go project's dependencies.
Explore the docs »
Report Bug
·
Request Feature
Table of Contents
go-showdeps is an interactive terminal UI for navigating your Go project's dependencies. It can be configured to highlight and rank packages according to custom rules.
- Go 1.16+
- Install using Go
go install github.com/grab/go-showdeps@latest
Run go-showdeps
from the root of your Go project.
Usage of go-showdeps:
-c string
The path of the configuration file (shorthand)
-config-file string
The path of the configuration file
-path-prefix string
The prefix to strip from package names. Requires StripPath
-strip-path
If set, will strip PathPrefix from package names
Environment variables:
CONFIG string
STRIP_PATH bool
PATH_PREFIX string
Custom rules can be configured by creating a configuration file in the following locations (in order of priority):
- A YAML file specified on the command-line via the
-c
/--config-file
flag. - A
.go-showdeps.yml
file in the current directory. $HOME/.go-showdeps.yml
Example configuration file:
---
rules:
- regex: internal/
label: Internal package
color: '#aa0000'
priority: 9
- regex: ^github
label: Package from GitHub
color: '#007700'
priority: 1
go-showdeps expects to run with Go modules enabled for best results. However, if you experience slowness in large projects it may be possible to speed it up by setting GO111MODULE=off
.
See the open issues for a full list of proposed features (and known issues).
If you have a suggestion that would make this project better, please fork the repo and create a pull request. You can also simply open an issue with the tag "enhancement".
Distributed under the MIT License. See LICENSE for more information.
Project Link: https://github.com/grab/go-showdeps