fileasm

package
v0.7.0 Latest Latest
Warning

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

Go to latest
Published: Jul 17, 2026 License: MIT Imports: 6 Imported by: 0

Documentation

Overview

Package fileasm is the single choke-point for generated-file scaffolding: the DO-NOT-EDIT header, package clause, grouped imports and gofmt.

Index

Constants

View Source
const Header = "// Code generated by go-api-sdk-apple-dm-codegen. DO NOT EDIT.\n"

Header is the generated-file marker. It doubles as the prune sentinel: files that begin with it and are not rewritten in a run are deleted.

Variables

This section is empty.

Functions

func Assemble

func Assemble(pkg string, docComment string, imports []Import, body string) ([]byte, error)

Assemble builds a complete, gofmt-formatted Go file.

func WriteFile

func WriteFile(path, pkg, docComment string, imports []Import, body string) error

WriteFile assembles and writes a generated file, creating the directory.

Types

type Import

type Import struct {
	Alias string
	Path  string
}

Import is one import spec.

Jump to

Keyboard shortcuts

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