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

Cannot generate code #50

Closed
Nokel81 opened this issue Sep 27, 2019 · 1 comment
Closed

Cannot generate code #50

Nokel81 opened this issue Sep 27, 2019 · 1 comment

Comments

@Nokel81
Copy link

Nokel81 commented Sep 27, 2019

I have installed goqueryset which looks something like the following:

// go:generate goqueryset -in types.go

// gen:qs
type Object struct {
	ID                 id.TargetID `gorm:"PRIMARY_KEY"`
	LastSeen           *LastSeen   `gorm:"foreignkey:TargetID"`
	RegistrationStatus database.RegistrationStatus
	RegistrationToken  string `gorm:"UNIQUE"`
}

// gen:qs
type LastSeen struct {
	TargetID id.TargetID
	Time     time.Time
}

However, if I run the following go generate in the same folder that file is, I get an exit code of 0 and no file

@derElektrobesen
Copy link
Collaborator

The problem is with go:generate, not with goqueryset.

Just remove the space symbol before go:generate and it will work.

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

No branches or pull requests

2 participants