From f93d14c3323a9c33db8efab2595cb835a4f6cab2 Mon Sep 17 00:00:00 2001 From: Giovanni Harting <539@idlegandalf.com> Date: Tue, 27 Dec 2022 17:56:37 +0100 Subject: [PATCH] export non-makepkg flags, resolves #149 --- proto_package.go | 2 +- utils.go | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/proto_package.go b/proto_package.go index d8995cb..9133b9a 100644 --- a/proto_package.go +++ b/proto_package.go @@ -145,7 +145,7 @@ func (p *ProtoPackage) build(ctx context.Context) (time.Duration, error) { // which leads to errors when it's trying to remove the same temporary download file. // This can be removed as soon as we can pass separate cache locations to makechrootpkg. rand.Seed(time.Now().UnixNano()) - time.Sleep(time.Duration(rand.Float32()*60) * time.Second) //nolint:gosec + time.Sleep(time.Duration(rand.Float32()*60) * time.Second) //nolint:gomnd,gosec start := time.Now().UTC() chroot := "build_" + uuid.New().String() diff --git a/utils.go b/utils.go index 960c685..7d7097b 100644 --- a/utils.go +++ b/utils.go @@ -856,7 +856,7 @@ func parseFlagSection(section interface{}, makepkgConf, march string) (string, e if len(orgMatch) == 0 { // no match found, assume env var and append it log.Debugf("no match found for %s:%v, appending", subSec, subMap) - makepkgConf += fmt.Sprintf("\n%s=%s", strings.ToUpper(subSec.(string)), replaceStringsFromMap(subMap.(string), replaceMap)) + makepkgConf += fmt.Sprintf("\nexport %s=%s", strings.ToUpper(subSec.(string)), replaceStringsFromMap(subMap.(string), replaceMap)) continue }