示例#1
0
文件: context.go 项目: liftup/aptly
// InitContext initializes context with default settings
func InitContext(flags *flag.FlagSet) error {
	var err error

	if context != nil {
		panic("context already initialized")
	}

	context, err = ctx.NewContext(flags)

	return err
}
示例#2
0
文件: main.go 项目: bsundsrud/slapt
func initCtx(flags *flag.FlagSet) error {
	var err error
	context, err = ctx.NewContext(flags)
	return err

}