From 5d0a2d4a095d87fbada8a7c5e1e2bf0f5efa648c Mon Sep 17 00:00:00 2001 From: Jeff Carr Date: Wed, 15 Oct 2025 06:08:15 -0500 Subject: rewrite this ancient code --- build.go | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) (limited to 'build.go') diff --git a/build.go b/build.go index 45bdc11..8753b43 100644 --- a/build.go +++ b/build.go @@ -7,6 +7,7 @@ import ( "path/filepath" "time" + "go.wit.com/lib/debian" "go.wit.com/lib/gui/shell" "go.wit.com/lib/protobuf/gitpb" "go.wit.com/log" @@ -217,9 +218,15 @@ func buildPackage(repo *gitpb.Repo) (bool, error) { } } - if !writeDebianControlFile(repo) { - return false, errors.New("write control file") + controlfile := debian.MakeControlFile(me.pb) + controlfile += "\n" + log.Info(controlfile) + if err := os.WriteFile("files/DEBIAN/control", []byte(controlfile), 0644); err != nil { + me.sh.BadExit("write err files/DEBIAN/control", err) } + // if !writeDebianControlFile(repo) { + // return false, errors.New("write control file") + // } if shell.Exists("postinst") { repo.RunVerbose([]string{"cp", "postinst", "files/DEBIAN/"}) } -- cgit v1.2.3