mirror of
https://github.com/securego/gosec.git
synced 2025-03-17 20:57:54 +02:00
move utils to separate executable
This commit is contained in:
parent
e925d3c347
commit
4c49716f0e
@ -15,6 +15,7 @@
|
||||
package main
|
||||
|
||||
import (
|
||||
"flag"
|
||||
"fmt"
|
||||
"go/ast"
|
||||
"go/importer"
|
||||
@ -274,3 +275,14 @@ func dumpImports(files ...string) {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
func main() {
|
||||
tools := newUtils()
|
||||
flag.Var(tools, "tool", "Utils to assist with rule development")
|
||||
flag.Parse()
|
||||
|
||||
if len(tools.call) > 0 {
|
||||
tools.run(flag.Args()...)
|
||||
os.Exit(0)
|
||||
}
|
||||
}
|
Loading…
x
Reference in New Issue
Block a user