From 2d192c485cf5ff24c11b528154a28f72b01aa71b Mon Sep 17 00:00:00 2001 From: "Andrew Jackson (Ajax)" Date: Thu, 9 Nov 2023 20:45:47 -0600 Subject: [PATCH] fix: lp: config set - must excl path --- cmd/lotus-provider/config.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/cmd/lotus-provider/config.go b/cmd/lotus-provider/config.go index 04ad0b2ec..7e2e5faea 100644 --- a/cmd/lotus-provider/config.go +++ b/cmd/lotus-provider/config.go @@ -7,6 +7,7 @@ import ( "fmt" "io" "os" + "path" "strings" "github.com/BurntSushi/toml" @@ -84,7 +85,7 @@ var configSetCmd = &cli.Command{ return fmt.Errorf("cannot open file %s: %w", args.First(), err) } if name == "" { - name = strings.Split(args.First(), ".")[0] + name = strings.Split(path.Base(args.First()), ".")[0] } } bytes, err := io.ReadAll(stream)