Skip to content

Commit c02325d

Browse files
committed
fix: Add internal/generated/imports.go for vendoring of generated sources
The move to using generated schemas meant that 'go mod vendor' didn't see the imports in the generated code. This commit adds an otherwise empty imports.go that contains the imports so offline builds can continue to work. It's hidden behind a //go:build imports so there's no impact at build or runtime.
1 parent bb1fe6a commit c02325d

File tree

1 file changed

+16
-0
lines changed

1 file changed

+16
-0
lines changed

internal/generated/imports.go

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
// go:build imports
2+
package generated
3+
4+
// This is only here for vendoring
5+
6+
import (
7+
_ "github.com/hashicorp/terraform-plugin-framework/attr"
8+
_ "github.com/hashicorp/terraform-plugin-framework/resource/schema"
9+
_ "github.com/hashicorp/terraform-plugin-framework/resource/schema/boolplanmodifier"
10+
_ "github.com/hashicorp/terraform-plugin-framework/resource/schema/int64planmodifier"
11+
_ "github.com/hashicorp/terraform-plugin-framework/resource/schema/planmodifier"
12+
_ "github.com/hashicorp/terraform-plugin-framework/resource/schema/stringplanmodifier"
13+
_ "github.com/hashicorp/terraform-plugin-framework/types"
14+
_ "github.com/hashicorp/terraform-plugin-framework/types/basetypes"
15+
_ "libvirt.org/go/libvirtxml"
16+
)

0 commit comments

Comments
 (0)