git

package module
v0.0.4 Latest Latest
Warning

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

Go to latest
Published: Apr 15, 2022 License: Apache-2.0 Imports: 10 Imported by: 1

README

git

Git命令封装,提供如下命令

  • 配置
    • 用户
    • 作者
    • 邮箱
  • 远端
    • 添加
    • 删除
    • 推送
    • 提交

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Add

func Add(opts ...fileOption) error

func Args

func Args(args ...interface{}) *optionArgs

Args 参数

func Async

func Async() *optionAsync

Async 配置异步执行

func Auth

func Auth(opts ...authOption) error

func Author

func Author(author string, opts ...option) error

func Branch

func Branch(branch string) *optionBranch

Branch 分支

func Clean added in v0.0.3

func Clean(opts ...cleanOption) (err error)

func Commit

func Commit(message string, opts ...fileOption) (err error)

func Contains

func Contains(contains string) *optionContains

Contains 检查是否包含字符串

func Dir

func Dir(dir string) *optionDir

Dir 目录

func DisablePwe

func DisablePwe() *optionPwe

DisablePwe 禁用PWE

func Email

func Email(email string, opts ...option) error

func Env

func Env(key string, value string) *optionEnvironment

Env 环境变量

func Environment

func Environment(key string, value string) *optionEnvironment

Environment 环境变量

func Exec

func Exec(opts ...option) error

func Filenames

func Filenames(filenames ...string) *optionFile

Filenames 配置命令执行目录

func Folder added in v0.0.3

func Folder(folder string) *optionDir

Folder 目录

func Init added in v0.0.3

func Init(opts ...option) error

func Latest added in v0.0.3

func Latest() *optionSkip

Latest 最后

func Name

func Name(name string) *optionName

Name 名称

func Netrc

func Netrc(uri string, username string, password string) *optionAuth

Netrc 用户名密码

func Push

func Push(opts ...pushOption) error

func Pwe

func Pwe() *optionPwe

Pwe 启用PWE

func Remote

func Remote(url string, opts ...remoteOption) (err error)

func SafeDirectory added in v0.0.2

func SafeDirectory(opts ...option) error

func Second added in v0.0.3

func Second() *optionSkip

Second 第二个

func Skip

func Skip(skip int) *optionSkip

Skip 跳跃数

func Ssh added in v0.0.3

func Ssh(key string, opts ...sshOption) *optionAuth

Ssh 安全连接

func String

func String(output *string) *optionString

String 字符串输出

func StringEnv

func StringEnv(env string) *optionStringEnvironments

StringEnv 环境变量

func StringEnvironment

func StringEnvironment(environment string) *optionStringEnvironments

StringEnvironment 环境变量

func StringEnvironments

func StringEnvironments(environments ...string) *optionStringEnvironments

StringEnvironments 环境变量列表

func StringEnvs

func StringEnvs(envs ...string) *optionStringEnvironments

StringEnvs 环境变量列表

func Sync

func Sync() *optionAsync

Sync 配置同步执行

func Tag

func Tag(opts ...tagOption) (tag string, err error)

func User

func User(author string, email string, opts ...option) (err error)

Types

This section is empty.

Jump to

Keyboard shortcuts

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