Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Better error message when no package name found #40

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

susisu
Copy link

@susisu susisu commented Aug 16, 2019

Fixes (in a sense) #35

The error message is a bit confusing when no package name found for the working directory (for example, an empty directory).

$ go run github.com/vektah/dataloaden UserLoader uint64 *example.com/model.User
unable to gofmt:/path/to/example.com/dataloader/userloader_gen.go:6:1: expected 'IDENT', found 'import'
exit status 2

This pr makes the message clearer.

$ go run github.com/vektah/dataloaden UserLoader uint64 *example.com/model.User
unable to find package name for /path/to/example.com/dataloader
exit status 2

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant