support for running gitleaks w no args

This commit is contained in:
zricethezav committed 2018-03-01 19:14:20 -06:00
1 parent 39c9cb617c
commit d85c8d8abd
2 files changed
+3 -1

No files matched your search

+1
View File
@@ -22,6 +22,7 @@ var (
assignRegex *regexp.Regexp
fileDiffRegex *regexp.Regexp
opts *Options
pwd string
)
func init() {
+2 -1
View File
@@ -171,7 +171,8 @@ func defaultOptions() (*Options, error) {
func (opts *Options) parseOptions(args []string) error {
if len(args) == 0 {
help()
opts.LocalMode = true
opts.RepoPath, _ = os.Getwd()
}
for i := 0; i < len(args); i++ {