Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/766b/godox
GoDoX extract speficic comments from Go code based on keywords
https://github.com/766b/godox
go godox linter todo
Last synced: 3 months ago
JSON representation
GoDoX extract speficic comments from Go code based on keywords
- Host: GitHub
- URL: https://github.com/766b/godox
- Owner: 766b
- License: mit
- Created: 2018-03-05T02:35:27.000Z (over 6 years ago)
- Default Branch: master
- Last Pushed: 2021-12-03T08:38:54.000Z (almost 3 years ago)
- Last Synced: 2024-06-19T03:10:16.843Z (5 months ago)
- Topics: go, godox, linter, todo
- Language: Go
- Size: 58.6 KB
- Stars: 9
- Watchers: 2
- Forks: 5
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
GoDoX
===
GoDoX extracts comments from Go code based on keywords![VSC Preview](./docs/vsc.png)
Installation
---go get -u github.com/766b/godox
Usage
---
Any comment lines starting with `TODO` or `FIX` (or other specified keywords, case insensitive) are extracted. If `TODO`/`FIX` comments is longer that 1 line, then only first line will be extracted.$ godox [] [...]
$ godox -help
-keys string
Change keywords (default "todo,bug,fix")$ godox ./path/to/directory ./path/to/secondary/directory
example.go:3:1:TODO: Implement io.Writer interface
example.go:7:14:TODO: Rename field
example.go:10:1:TODO: Add JWT verification
example.go:15:3:FIX: Something that is brokenUsage with Go Meta Linter
---gometalinter --linter=godox:godox -keys=todo,fix:PATH:LINE:COL:MESSAGE --enable=godox [] [...]
Usage with Visual Studio Code
---
To use `GoDoX` with `VS Code` you need to have [Go Meta Linter](https://github.com/alecthomas/gometalinter) installed, then add following to your `User Settings (Ctrl+,)`"go.lintTool": "gometalinter",
"go.lintFlags": [
"--disable-all", // Disable all linters
"--linter=godox:godox:PATH:LINE:COL:MESSAGE"
"--enable=godox",
"--enable=golint", // Enable any other linters you want to use
],If you want to use custom keywords, use following line:
"--linter=`godox:godox -keys=bug,todo,fixme:PATH:LINE:COL:MESSAGE`",