Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions components/client/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ import (
"os/user"
"path"

"github.com/go-git/go-billy/v5/osfs"
ui "github.com/gizak/termui/v3"
"github.com/gizak/termui/v3/widgets"
"github.com/pingcap/tiup/pkg/environment"
Expand Down Expand Up @@ -98,11 +99,12 @@ func connect(target string) error {
if err != nil {
return fmt.Errorf("can't get current user: %s", err.Error())
}
l, err := rline.New(false, "", env.HistoryFile(u))
l, err := rline.New(false, false, false, "", env.HistoryFile(u))
if err != nil {
return fmt.Errorf("can't open history file: %s", err.Error())
}
h := handler.New(l, u, os.Getenv(localdata.EnvNameInstanceDataDir), true)
dataDir := os.Getenv(localdata.EnvNameInstanceDataDir)
h := handler.New(l, u, dataDir, osfs.New(dataDir), true)
if err = h.Open(context.TODO(), ep.dsn); err != nil {
return fmt.Errorf("can't open connection to %s: %s", ep.dsn, err.Error())
}
Expand Down
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ require (
github.com/spf13/pflag v1.0.5
github.com/stretchr/testify v1.10.0
github.com/vishvananda/netlink v0.0.0-20210530105856-14e832ae1e8f
github.com/xo/usql v0.14.0
github.com/xo/usql v0.19.19
go.etcd.io/etcd/client/pkg/v3 v3.5.7
go.etcd.io/etcd/client/v3 v3.5.7
go.uber.org/atomic v1.11.0
Expand Down
Loading