format

package
v2.0.0-rc6 Latest Latest
Warning

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

Go to latest
Published: Oct 3, 2023 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	// SearchDir the swag would be parse
	SearchDir string

	// excludes dirs and files in SearchDir,comma separated
	Excludes string

	// MainFile (DEPRECATED)
	MainFile string
}

Config specifies configuration for a format run

type Format

type Format struct {
	// contains filtered or unexported fields
}

Format implements `fmt` command for formatting swag comments in Go source files.

func New

func New() *Format

New creates a new Format instance

func (*Format) Build

func (f *Format) Build(config *Config) error

Build runs formatter according to configuration in config

Jump to

Keyboard shortcuts

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