Skip to content
This repository has been archived by the owner on Feb 14, 2022. It is now read-only.

Import overriding #3

Open
OdaDaisuke opened this issue Oct 13, 2019 · 0 comments
Open

Import overriding #3

OdaDaisuke opened this issue Oct 13, 2019 · 0 comments
Labels
bug Something isn't working

Comments

@OdaDaisuke
Copy link
Owner

quikman overrides existing import dec like this.
https://github.com/OdaDaisuke/quikman/blob/master/cmd/quikman/main.go#L69

This logic has some problem.

CASE: No import dec

Example code is shown below.

package main

type XXXModel struct {
}

Output file goes like this.

package main

type XXXModel struct {
}

...auto generated code...

type XXXRepository struct {
  dbCtx *sql.DB
}

...

Generated code uses database/sql package, but the file has no import decl.

@OdaDaisuke OdaDaisuke added the bug Something isn't working label Oct 13, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant