Browse Source
Merge pull request #827 from suilongfei/master
change log_dir to logdir for the "flag redefined:log_dir" error when use another package with "github.com/golang/glog"
pull/831/head
Chris Lu
6 years ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with
2 additions and
2 deletions
-
weed/glog/glog.go
-
weed/glog/glog_file.go
|
@ -46,7 +46,7 @@ |
|
|
// -stderrthreshold=ERROR
|
|
|
// -stderrthreshold=ERROR
|
|
|
// Log events at or above this severity are logged to standard
|
|
|
// Log events at or above this severity are logged to standard
|
|
|
// error as well as to files.
|
|
|
// error as well as to files.
|
|
|
// -log_dir=""
|
|
|
|
|
|
|
|
|
// -logdir=""
|
|
|
// Log files will be written to this directory instead of the
|
|
|
// Log files will be written to this directory instead of the
|
|
|
// default temporary directory.
|
|
|
// default temporary directory.
|
|
|
//
|
|
|
//
|
|
|
|
@ -38,7 +38,7 @@ var logDirs []string |
|
|
|
|
|
|
|
|
// If non-empty, overrides the choice of directory in which to write logs.
|
|
|
// If non-empty, overrides the choice of directory in which to write logs.
|
|
|
// See createLogDirs for the full list of possible destinations.
|
|
|
// See createLogDirs for the full list of possible destinations.
|
|
|
var logDir = flag.String("log_dir", "", "If non-empty, write log files in this directory") |
|
|
|
|
|
|
|
|
var logDir = flag.String("logdir", "", "If non-empty, write log files in this directory") |
|
|
|
|
|
|
|
|
func createLogDirs() { |
|
|
func createLogDirs() { |
|
|
if *logDir != "" { |
|
|
if *logDir != "" { |
|
|