Avoid using log.Fatal
in pkg/*
(#1705)
* fix: common * fix: in runner * fix: decodeNode * fix: GetMatrixes * Revert "fix: common" This reverts commit 6599803b6ae3b7adc168ef41b4afd4d89fc22f34. * fix: GetOutboundIP * test: fix cases --------- Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
This commit is contained in:
@@ -18,7 +18,6 @@ import (
|
||||
"strings"
|
||||
|
||||
"github.com/opencontainers/selinux/go-selinux"
|
||||
log "github.com/sirupsen/logrus"
|
||||
|
||||
"github.com/nektos/act/pkg/common"
|
||||
"github.com/nektos/act/pkg/container"
|
||||
@@ -361,7 +360,8 @@ func (rc *RunContext) ActionCacheDir() string {
|
||||
if home, err := os.UserHomeDir(); err == nil {
|
||||
xdgCache = filepath.Join(home, ".cache")
|
||||
} else if xdgCache, err = filepath.Abs("."); err != nil {
|
||||
log.Fatal(err)
|
||||
// It's almost impossible to get here, so the temp dir is a good fallback
|
||||
xdgCache = os.TempDir()
|
||||
}
|
||||
}
|
||||
return filepath.Join(xdgCache, "act")
|
||||
|
Reference in New Issue
Block a user