aboutsummaryrefslogtreecommitdiffstats
path: root/cmd/ethereum
diff options
context:
space:
mode:
authorobscuren <geffobscura@gmail.com>2014-10-31 19:56:05 +0800
committerobscuren <geffobscura@gmail.com>2014-10-31 19:56:05 +0800
commitb1c247231b11f313ca0eedff75ea563926d23f68 (patch)
tree48b2136cb65e69cb79ffac80f3cc3fdf9dba1cc8 /cmd/ethereum
parentfd9da72536b73351bbcdc1e9dbbbb8c0e4bfb21b (diff)
downloaddexon-b1c247231b11f313ca0eedff75ea563926d23f68.tar.gz
dexon-b1c247231b11f313ca0eedff75ea563926d23f68.tar.zst
dexon-b1c247231b11f313ca0eedff75ea563926d23f68.zip
ethlog => logger
Diffstat (limited to 'cmd/ethereum')
-rw-r--r--cmd/ethereum/cmd.go4
-rw-r--r--cmd/ethereum/flags.go4
-rw-r--r--cmd/ethereum/main.go5
-rw-r--r--cmd/ethereum/repl/repl.go8
4 files changed, 11 insertions, 10 deletions
diff --git a/cmd/ethereum/cmd.go b/cmd/ethereum/cmd.go
index a0225b652..d8cb19eaf 100644
--- a/cmd/ethereum/cmd.go
+++ b/cmd/ethereum/cmd.go
@@ -38,11 +38,11 @@ func InitJsConsole(ethereum *eth.Ethereum) {
func ExecJsFile(ethereum *eth.Ethereum, InputFile string) {
file, err := os.Open(InputFile)
if err != nil {
- logger.Fatalln(err)
+ clilogger.Fatalln(err)
}
content, err := ioutil.ReadAll(file)
if err != nil {
- logger.Fatalln(err)
+ clilogger.Fatalln(err)
}
re := javascript.NewJSRE(ethereum)
utils.RegisterInterrupt(func(os.Signal) {
diff --git a/cmd/ethereum/flags.go b/cmd/ethereum/flags.go
index 892ea0036..783944cf2 100644
--- a/cmd/ethereum/flags.go
+++ b/cmd/ethereum/flags.go
@@ -25,7 +25,7 @@ import (
"os/user"
"path"
- "github.com/ethereum/go-ethereum/ethlog"
+ "github.com/ethereum/go-ethereum/logger"
"github.com/ethereum/go-ethereum/vm"
)
@@ -98,7 +98,7 @@ func Init() {
flag.StringVar(&Datadir, "datadir", defaultDataDir(), "specifies the datadir to use")
flag.StringVar(&ConfigFile, "conf", defaultConfigFile, "config file")
flag.StringVar(&DebugFile, "debug", "", "debug file (no debugging if not set)")
- flag.IntVar(&LogLevel, "loglevel", int(ethlog.InfoLevel), "loglevel: 0-5: silent,error,warn,info,debug,debug detail)")
+ flag.IntVar(&LogLevel, "loglevel", int(logger.InfoLevel), "loglevel: 0-5: silent,error,warn,info,debug,debug detail)")
flag.BoolVar(&DiffTool, "difftool", false, "creates output for diff'ing. Sets LogLevel=0")
flag.StringVar(&DiffType, "diff", "all", "sets the level of diff output [vm, all]. Has no effect if difftool=false")
flag.BoolVar(&ShowGenesis, "genesis", false, "Dump the genesis block")
diff --git a/cmd/ethereum/main.go b/cmd/ethereum/main.go
index 71b9b72f1..fa85865fc 100644
--- a/cmd/ethereum/main.go
+++ b/cmd/ethereum/main.go
@@ -23,9 +23,10 @@ import (
"runtime"
"github.com/ethereum/go-ethereum/chain"
- "github.com/ethereum/go-ethereum/ethlog"
"github.com/ethereum/go-ethereum/ethutil"
+ "github.com/ethereum/go-ethereum/logger"
"github.com/ethereum/go-ethereum/utils"
+ "github.com/ethgo.old/ethlog"
)
const (
@@ -33,7 +34,7 @@ const (
Version = "0.7.0"
)
-var logger = ethlog.NewLogger("CLI")
+var clilogger = logger.NewLogger("CLI")
func main() {
runtime.GOMAXPROCS(runtime.NumCPU())
diff --git a/cmd/ethereum/repl/repl.go b/cmd/ethereum/repl/repl.go
index 101bb058b..a5146fecd 100644
--- a/cmd/ethereum/repl/repl.go
+++ b/cmd/ethereum/repl/repl.go
@@ -25,12 +25,12 @@ import (
"path"
"github.com/ethereum/go-ethereum"
- "github.com/ethereum/go-ethereum/ethlog"
"github.com/ethereum/go-ethereum/ethutil"
"github.com/ethereum/go-ethereum/javascript"
+ "github.com/ethereum/go-ethereum/logger"
)
-var logger = ethlog.NewLogger("REPL")
+var repllogger = logger.NewLogger("REPL")
type Repl interface {
Start()
@@ -59,7 +59,7 @@ func NewJSRepl(ethereum *eth.Ethereum) *JSRepl {
func (self *JSRepl) Start() {
if !self.running {
self.running = true
- logger.Infoln("init JS Console")
+ repllogger.Infoln("init JS Console")
reader := bufio.NewReader(self.history)
for {
line, err := reader.ReadString('\n')
@@ -80,7 +80,7 @@ func (self *JSRepl) Stop() {
if self.running {
self.running = false
self.re.Stop()
- logger.Infoln("exit JS Console")
+ repllogger.Infoln("exit JS Console")
self.history.Close()
}
}