refactor: 整理结构和 maker 构建方式
This commit is contained in:
@@ -9,7 +9,8 @@ import (
|
||||
)
|
||||
|
||||
type installer struct {
|
||||
target string
|
||||
workdir string
|
||||
target string
|
||||
}
|
||||
|
||||
func (i *installer) targetOK(ctx context.Context) error {
|
||||
@@ -34,6 +35,6 @@ func (i *installer) targetOK(ctx context.Context) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func NewInstaller(target string) *installer {
|
||||
return &installer{target: target}
|
||||
func NewInstaller(workdir, target string) *installer {
|
||||
return &installer{workdir: workdir, target: target}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user