mgmt

package
v0.0.0-...-615c734 Latest Latest
Warning

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

Go to latest
Published: Apr 23, 2024 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ModuleVersionPrefix = "module-version: "
	ChangelogMD         = "CHANGELOG.md"
)

Variables

View Source
var (
	ModuleVersionRegex           = regexp.MustCompile(`moduleVersion\s*=\s*\".*v.+"`)
	ChangelogPosWithPreviewRegex = regexp.MustCompile(`##\s*(?P<version>.+)\s*\((\d{4}-\d{2}-\d{2}|Unreleased)\)`)
)

Functions

func AddChangelogToFile

func AddChangelogToFile(additionalChangelog string, version *semver.Version, packageRootPath, releaseDate string) (string, error)

add new changelog md to changelog file

func AutorestMdVersion

func AutorestMdVersion(md string) (*semver.Version, error)

从 autorest.md 中获取 module-version

func ExecGo

func ExecGo(path string, pameters ...string) error

func GoModTidy

func GoModTidy(dir string) error

func GoVet

func GoVet(dir string) error

func RemoveGoModRequire

func RemoveGoModRequire(gomodFile string) error

func ReplaceVersion

func ReplaceVersion(packageRootPath string, newVersion string) error

replace version: use `module-version: ` prefix to locate version in autorest.md file, use version = "v*.*.*" regrex to locate version in constants.go file

Types

This section is empty.

Jump to

Keyboard shortcuts

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