generate

package
v0.7.0-8a Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 11, 2026 License: MIT Imports: 10 Imported by: 1 module, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

View Source
var CLIVersion = func() string { return "dev" }

CLIVersion reports the running CLI's own version; the root command assigns it at startup. A release version becomes the toolchain pin scaffolds record.

View Source
var (
	FactoryCmd = &cobra.Command{
		Use:   "factory",
		Short: "Scaffold a new factory",
		Long: `Scaffold a new factory directory.

The generated directory contains a main.ub source file with empty
placeholder blocks the author fills in. The config.ub is operator
supplied per stack; use init-config (when available) or write
it by hand.

Examples:
  unobin generate factory -o ./my-factory`,

		RunE: func(cmd *cobra.Command, args []string) error {
			return runFactory(cmd, factoryCfg)
		},
	}
)
View Source
var (
	GolibraryCmd = &cobra.Command{
		Use:   "golibrary",
		Short: "Generate a Go library skeleton from a TF provider schema",
		Long: `Generate a Go library from a Terraform provider schema.

The generated Go library contains typed structs with ub tags and
CRUD method stubs for every resource in the provider.

Examples:
  unobin generate golibrary --from tf --provider random --go-module-path example.com/libraries/random
  unobin generate golibrary --from tf --provider aws -o ./aws-library --go-module-path example.com/libraries/aws`,

		RunE: func(cmd *cobra.Command, args []string) error {
			return runGenerate(cmd, golibraryCfg)
		},
	}
)
View Source
var (
	UblibraryCmd = &cobra.Command{
		Use:   "ublibrary",
		Short: "Scaffold a new UB library",
		Long: `Scaffold a new UB library directory.

The generated directory contains one starter composite type file named
resource-<type>.ub. The directory listing is the manifest, so there is
no separate manifest file. Blocks are empty with TODO comment markers;
the author fills them in.

Examples:
  unobin generate ublibrary -o ./greeter
  unobin generate ublibrary -o ./greeter --type greeting`,

		RunE: func(cmd *cobra.Command, args []string) error {
			return runUblibrary(cmd, ublibraryCfg)
		},
	}
)

Functions

This section is empty.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL