pub struct Opts {
pub format: Format,
pub async_: AsyncFilterSet,
pub generate_stubs: bool,
pub pkg_name: Option<String>,
pub export_pkg_name: Option<String>,
pub print_remote_pkg_version: bool,
pub include_versions: bool,
}Fields§
§format: FormatWhether or not gofmt should be used (if present) to format generated
code.
async_: AsyncFilterSet§generate_stubs: boolIf true, generate stub functions for any exported functions and/or resources.
pkg_name: Option<String>If specified, organize the bindings into a package for use as a library;
otherwise (if None), the bindings will be organized for use as a
standalone executable.
export_pkg_name: Option<String>When --pkg-name is specified, optionally specify a different package
for exports.
This allows you to put the exports and imports in separate packages when
building a library. If only --pkg-name is specified, this will
default to that value.
print_remote_pkg_version: boolPrint the version of the remote package being used for the shared WIT types.
Must be specified in addition to the pkg-name flag.
include_versions: boolWhen generating Go package names, include the WIT package version even if only one version of that package is referenced by the specified world.
By default, the version will only be included in the name if the world references more than one version of the WIT package.