mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-05-12 11:06:40 +00:00
console: fix windows color transformation issue
This commit is contained in:
parent
fdd61b83ff
commit
d251d48439
1 changed files with 2 additions and 1 deletions
|
|
@ -30,6 +30,7 @@ import (
|
||||||
"github.com/ethereum/go-ethereum/internal/jsre"
|
"github.com/ethereum/go-ethereum/internal/jsre"
|
||||||
"github.com/ethereum/go-ethereum/internal/web3ext"
|
"github.com/ethereum/go-ethereum/internal/web3ext"
|
||||||
"github.com/ethereum/go-ethereum/rpc"
|
"github.com/ethereum/go-ethereum/rpc"
|
||||||
|
"github.com/mattn/go-colorable"
|
||||||
"github.com/peterh/liner"
|
"github.com/peterh/liner"
|
||||||
"github.com/robertkrimen/otto"
|
"github.com/robertkrimen/otto"
|
||||||
)
|
)
|
||||||
|
|
@ -80,7 +81,7 @@ func New(config Config) (*Console, error) {
|
||||||
config.Prompt = DefaultPrompt
|
config.Prompt = DefaultPrompt
|
||||||
}
|
}
|
||||||
if config.Printer == nil {
|
if config.Printer == nil {
|
||||||
config.Printer = os.Stdout
|
config.Printer = colorable.NewColorableStdout()
|
||||||
}
|
}
|
||||||
// Initialize the console and return
|
// Initialize the console and return
|
||||||
console := &Console{
|
console := &Console{
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue