mirror of
https://github.com/thegeeklab/wp-opentofu.git
synced 2024-06-02 18:39:41 +02:00
cleanup
This commit is contained in:
parent
28eba4fb31
commit
8de4b466cd
|
@ -11,8 +11,8 @@ import (
|
|||
"time"
|
||||
|
||||
"github.com/thegeeklab/wp-opentofu/plugin"
|
||||
"github.com/thegeeklab/wp-plugin-go/v3/docs"
|
||||
wp_template "github.com/thegeeklab/wp-plugin-go/v3/template"
|
||||
plugin_docs "github.com/thegeeklab/wp-plugin-go/v3/docs"
|
||||
plugin_template "github.com/thegeeklab/wp-plugin-go/v3/template"
|
||||
)
|
||||
|
||||
func main() {
|
||||
|
@ -23,7 +23,7 @@ func main() {
|
|||
|
||||
p := plugin.New(nil)
|
||||
|
||||
out, err := wp_template.Render(context.Background(), client, tmpl, docs.GetTemplateData(p.App))
|
||||
out, err := plugin_template.Render(context.Background(), client, tmpl, plugin_docs.GetTemplateData(p.App))
|
||||
if err != nil {
|
||||
panic(err)
|
||||
}
|
||||
|
|
|
@ -4,7 +4,7 @@ import (
|
|||
"fmt"
|
||||
|
||||
"github.com/thegeeklab/wp-opentofu/tofu"
|
||||
wp "github.com/thegeeklab/wp-plugin-go/v3/plugin"
|
||||
plugin_base "github.com/thegeeklab/wp-plugin-go/v3/plugin"
|
||||
"github.com/urfave/cli/v2"
|
||||
)
|
||||
|
||||
|
@ -12,7 +12,7 @@ import (
|
|||
|
||||
// Plugin implements provide the plugin.
|
||||
type Plugin struct {
|
||||
*wp.Plugin
|
||||
*plugin_base.Plugin
|
||||
Settings *Settings
|
||||
}
|
||||
|
||||
|
@ -25,15 +25,15 @@ type Settings struct {
|
|||
Tofu tofu.Tofu
|
||||
}
|
||||
|
||||
func New(e wp.ExecuteFunc, build ...string) *Plugin {
|
||||
func New(e plugin_base.ExecuteFunc, build ...string) *Plugin {
|
||||
p := &Plugin{
|
||||
Settings: &Settings{},
|
||||
}
|
||||
|
||||
options := wp.Options{
|
||||
options := plugin_base.Options{
|
||||
Name: "wp-opentofu",
|
||||
Description: "Manage infrastructure with OpenTofu",
|
||||
Flags: Flags(p.Settings, wp.FlagsPluginCategory),
|
||||
Flags: Flags(p.Settings, plugin_base.FlagsPluginCategory),
|
||||
Execute: p.run,
|
||||
HideWoodpeckerFlags: true,
|
||||
}
|
||||
|
@ -50,7 +50,7 @@ func New(e wp.ExecuteFunc, build ...string) *Plugin {
|
|||
options.Execute = e
|
||||
}
|
||||
|
||||
p.Plugin = wp.New(options)
|
||||
p.Plugin = plugin_base.New(options)
|
||||
|
||||
return p
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue
Block a user