gitczcmd

package
v1.2.3 Latest Latest
Warning

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

Go to latest
Published: Jan 2, 2024 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	InputTypePrompt           = "选择或输入一个提交类型(必填): "
	InputScopePrompt          = "说明本次提交的影响范围(必填): "
	InputSubjectPrompt        = "对本次提交进行简短描述(必填): "
	InputBodyPrompt           = "对本次提交进行完整描述(选填): "
	InputBreakingChangePrompt = "如果当前代码版本与上一版本不兼容,对变动、变动的理由及迁移的方法进行描述(选填): "
	InputClosesPrompt         = "如果本次提交针对某个issue,列出关闭的issues(选填): "
)
View Source
var CzTypeList []CzType

Functions

func GenerateCommit

func GenerateCommit(czCommit *CzCommit) string

func GitCommit

func GitCommit(commit string) (err error)

func GitCz

func GitCz()

func Init

func Init()

func InputBody

func InputBody(line *liner.State) *string

func InputBreakingChange

func InputBreakingChange(line *liner.State) *string

func InputCloses

func InputCloses(line *liner.State) *string

func InputScope

func InputScope(line *liner.State) *string

func InputSubject

func InputSubject(line *liner.State) *string

func NewLine

func NewLine()

Types

type CzCommit

type CzCommit struct {
	Type           *CzType
	Scope          *string
	Subject        *string
	Body           *string
	BreakingChange *string
	Closes         *string
}

func UserOperate

func UserOperate(line *liner.State) CzCommit

type CzType

type CzType struct {
	Type    string `json:"code"`
	Message string `json:"description"`
}

func InputType

func InputType(line *liner.State) *CzType

Jump to

Keyboard shortcuts

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