Skip to content

Commit

Permalink
fix: fix build errror
Browse files Browse the repository at this point in the history
修复 -b 参数构建玲珑应用错误

Log: fix build error
  • Loading branch information
chenchongbiao authored and deepin-bot[bot] committed May 15, 2024
1 parent 1aedfda commit d8d203b
Showing 1 changed file with 8 additions and 7 deletions.
15 changes: 8 additions & 7 deletions cli/command/convert/convert.go
Original file line number Diff line number Diff line change
Expand Up @@ -196,19 +196,20 @@ func runConvert(options *convertOptions) error {

// 构建玲珑包
if options.buildFlag {
if ret, msg, err := comm.ExecAndWait(10, "sh", "-c",
fmt.Sprintf("cd %s && ll-builder build", appPath)); err != nil {
log.Logger.Infof("build %s success.", packConfig.File.Deb[idx].Name)
buildLinglongPath := filepath.Dir(linglongYamlPath)
if ret, msg, err := comm.ExecAndWait(1<<10, "sh", "-c",
fmt.Sprintf("cd %s && ll-builder build", buildLinglongPath)); err != nil {
log.Logger.Warnf("msg: %+v err:%+v, out: %+v", msg, err, ret)
} else {
log.Logger.Warnf("msg: %+v err:%+v, out: %+v", msg, err, ret)
}

// 导出玲珑包
if ret, msg, err := comm.ExecAndWait(10, "sh", "-c",
fmt.Sprintf("cd %s && ll-builder export", appPath)); err != nil {
log.Logger.Infof("%s export success.", packConfig.File.Deb[idx].Name)
} else {
if ret, msg, err := comm.ExecAndWait(1<<10, "sh", "-c",
fmt.Sprintf("cd %s && ll-builder export", buildLinglongPath)); err != nil {
log.Logger.Warnf("msg: %+v err:%+v, out: %+v", msg, err, ret)
} else {
log.Logger.Infof("%s export success.", packConfig.File.Deb[idx].Name)
}
}
}
Expand Down

0 comments on commit d8d203b

Please sign in to comment.