git-profile
git-profile copied to clipboard
panic: runtime error: invalid memory address or nil pointer dereference
I compiled a binary from the master branch and caught an error:
> git profile current
panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x2 addr=0x0 pc=0x1003a1b34]
goroutine 1 [running]:
github.com/dotzero/git-profile/git.(*Git).IsRepository(0x140000a4038)
/Users/dos/www/git-profile/git/git.go:22 +0x54
github.com/dotzero/git-profile/cmd.Current.func1(0x140000c0500?, {0x1003a4e30?, 0x0?, 0x0?})
/Users/dos/www/git-profile/cmd/current.go:22 +0x54
github.com/spf13/cobra.(*Command).execute(0x140000c0500, {0x100588460, 0x0, 0x0})
/Users/dos/www/git-profile/vendor/github.com/spf13/cobra/command.go:860 +0x4ac
github.com/spf13/cobra.(*Command).ExecuteC(0x14000098300)
/Users/dos/www/git-profile/vendor/github.com/spf13/cobra/command.go:974 +0x354
github.com/spf13/cobra.(*Command).Execute(...)
/Users/dos/www/git-profile/vendor/github.com/spf13/cobra/command.go:902
github.com/dotzero/git-profile/cmd.(*Cmd).Execute(0x14000098300)
/Users/dos/www/git-profile/cmd/root.go:57 +0x2c
main.main()
/Users/dos/www/git-profile/main.go:22 +0xc4