From b4d2ebc0ca79f89385e88963a032bcf5c87241ef Mon Sep 17 00:00:00 2001 From: lwch Date: Thu, 30 Sep 2021 10:26:24 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9build=5Fall.go=E8=84=9A?= =?UTF-8?q?=E6=9C=AC?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- build_all.go | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/build_all.go b/build_all.go index bec104f..a68027a 100644 --- a/build_all.go +++ b/build_all.go @@ -60,12 +60,24 @@ var targets = []target{ func main() { os.RemoveAll(releaseDir) runtime.Assert(os.MkdirAll(releaseDir, 0755)) + bindata() for _, target := range targets { logging.Info("build target %s/%s...", target.os, target.arch) build(target) } } +func bindata() { + cmd := exec.Command("go", "run", "contrib/bindata/main.go", + "-pkg", "shell", + "-o", "code/client/shell/assets.go", + "-prefix", "html/shell", + "html/shell/...") + cmd.Stdout = os.Stdout + cmd.Stderr = os.Stderr + runtime.Assert(cmd.Run()) +} + func build(t target) { os.RemoveAll(buildDir) runtime.Assert(os.MkdirAll(buildDir, 0755))