Documentation
¶
Index ¶
- Variables
- func CatchupFactory() (cli.Command, error)
- func ConfigFactory() (cli.Command, error)
- func Exec()
- func ExecCatchup(c contrib.Contrib, r repository.HeadReader) error
- func ExecGetConfig(key string, r repository.ConfigReader) (string, error)
- func ExecPush(c contrib.Contrib, r repository.Files) error
- func ExecSetup(c contrib.Contrib, repo repository.Files) error
- func ExecUpdateConfig(key, value string, r repository.ConfigWriter) error
- func NewContrib(repo repository.Repository) (contrib.Contrib, int)
- func NewRepo(base, remote string) (repository.Repository, int)
- func PushFactory() (cli.Command, error)
- func Register() map[string]cli.CommandFactory
- func SetupFactory() (cli.Command, error)
- type BasicOptions
- type OptionsParser
Constants ¶
This section is empty.
Variables ¶
View Source
var ( BuildTime string Version string BuildPlatform string )
Functions ¶
func CatchupFactory ¶
CatchupFactory of command `catchup`
func ExecCatchup ¶
func ExecCatchup(c contrib.Contrib, r repository.HeadReader) error
ExecCatchup catchup contrib with repo head
func ExecGetConfig ¶
func ExecGetConfig(key string, r repository.ConfigReader) (string, error)
ExecGetConfig get config
func ExecPush ¶
func ExecPush(c contrib.Contrib, r repository.Files) error
ExecPush push changed and deleted files to contrib
func ExecSetup ¶
func ExecSetup(c contrib.Contrib, repo repository.Files) error
ExecSetup setup command handler
func ExecUpdateConfig ¶
func ExecUpdateConfig(key, value string, r repository.ConfigWriter) error
ExecUpdateConfig update config
func NewContrib ¶
func NewContrib(repo repository.Repository) (contrib.Contrib, int)
func NewRepo ¶
func NewRepo(base, remote string) (repository.Repository, int)
NewRepo new repo instance
Types ¶
type BasicOptions ¶
type BasicOptions struct {
Base string `flag:"base" value:"" usage:"Base dir path to run syncer"`
Branch string `flag:"branch" value:"" usage:"Push a specific branch"`
Remote string `flag:"remote" value:"" usage:"Push to specific remote"`
}
BasicOptions basic options for command
type OptionsParser ¶
func OptionsBinder ¶
func OptionsBinder(options interface{}, flags *flag.FlagSet) OptionsParser
Click to show internal directories.
Click to hide internal directories.