To scaffold a new Terraform provider with Plugin Framework:
- If already in a Terraform provider workspace, confirm before creating a new one. Skip remaining steps if declined.
- Create a workspace root directory prefixed with
terraform-provider-. Run all subsequent steps inside it. - Initialize a new Go module.
- Run
go get -u github.com/hashicorp/terraform-plugin-framework@latest. - Write a
main.gofollowing the example. - Remove TODO comments from
main.go. - Run
go mod tidy. - Run
go build -o /dev/null. - Run
go test ./....