github.com/zignig/go-ipfs@v0.0.0-20141111235910-c9e5fdf55a52/core/commands/log.go (about) 1 package commands 2 3 import ( 4 "io" 5 6 "github.com/jbenet/go-ipfs/core" 7 u "github.com/jbenet/go-ipfs/util" 8 ) 9 10 // Log changes the log level of a subsystem 11 func Log(n *core.IpfsNode, args []string, opts map[string]interface{}, out io.Writer) error { 12 if err := u.SetLogLevel(args[0], args[1]); err != nil { 13 return err 14 } 15 16 log.Info("Changed LogLevel of %q to %q", args[0], args[1]) 17 return nil 18 }