Documentation ¶
Index ¶
- Constants
- Variables
- func AddChangelogToFile(additionalChangelog string, version *semver.Version, ...) (string, error)
- func AutorestMdVersion(md string) (*semver.Version, error)
- func ExecGo(path string, pameters ...string) error
- func GoModTidy(dir string) error
- func GoVet(dir string) error
- func RemoveGoModRequire(gomodFile string) error
- func ReplaceVersion(packageRootPath string, newVersion string) error
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 ¶
从 autorest.md 中获取 module-version
func RemoveGoModRequire ¶
func ReplaceVersion ¶
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.
Click to show internal directories.
Click to hide internal directories.