Closed SAGEof6iixPATHS closed 2 years ago
Got the same error.
same error.
panic: runtime error: index out of range [0] with length 0
goroutine 1 [running]: github.com/tillson/git-hound/cmd.getScanner(...) /root/Final_tool/git-hound/cmd/root.go:112 github.com/tillson/git-hound/cmd.glob..func1(0x104f640, 0x108a358, 0x0, 0x0) /root/Final_tool/git-hound/cmd/root.go:64 +0xb45 github.com/spf13/cobra.(Command).execute(0x104f640, 0xc0000202c0, 0x0, 0x0, 0x104f640, 0xc0000202c0) /root/go/pkg/mod/github.com/spf13/cobra@v0.0.7/command.go:842 +0x2c2 github.com/spf13/cobra.(Command).ExecuteC(0x104f640, 0x448b77, 0x100e000, 0xc000000180) /root/go/pkg/mod/github.com/spf13/cobra@v0.0.7/command.go:943 +0x336 github.com/spf13/cobra.(*Command).Execute(...) /root/go/pkg/mod/github.com/spf13/cobra@v0.0.7/command.go:883 github.com/tillson/git-hound/cmd.Execute() /root/Final_tool/git-hound/cmd/root.go:122 +0x36 main.main() /root/Final_tool/git-hound/main.go:10 +0x25
A quick workaround for this issue is to download and build the latest stable release (v1.3 at the time of writing this comment).
Debugging the issue, it seems that the root cause of the issue is the following commit: https://github.com/tillson/git-hound/commit/c9b91bac386e782b71da061c24e6bab2626d2ba9
More specifically, trying to access the first string value in the arguments' list at line 108
in the committed file cmd/root.go
.
I ran This command
echo "zapier.com" | git-hound --dig-files --dig-commits --many-results --threads 100
And got this error...