mirror of
https://github.com/nushell/nushell.git
synced 2024-11-22 00:13:21 +01:00
change LOG_FORMAT to NU_LOG_FORMAT in nu-std library (#10254)
this closes #10248 @fdncred pointed out the problem and he was correct 😄 I went ahead and made the simple change and the https://github.com/influxdata/influxdb_iox binary works like a charm... @amtoine hopefully there are no issues with this change I believe its a good one as other rust binaries might take advantage of this common environment variable as well...
This commit is contained in:
parent
f433b3102f
commit
6a374182a7
@ -31,7 +31,7 @@ export-env {
|
||||
"DEBUG": "D"
|
||||
}
|
||||
|
||||
$env.LOG_FORMAT = $"%ANSI_START%%DATE%|%LEVEL%|(ansi u)%MSG%%ANSI_STOP%"
|
||||
$env.NU_LOG_FORMAT = $"%ANSI_START%%DATE%|%LEVEL%|(ansi u)%MSG%%ANSI_STOP%"
|
||||
}
|
||||
|
||||
def log-types [] {
|
||||
@ -149,7 +149,7 @@ def handle-log [
|
||||
short: bool
|
||||
] {
|
||||
let log_format = if ($format_string | is-empty) {
|
||||
$env.LOG_FORMAT
|
||||
$env.NU_LOG_FORMAT
|
||||
} else {
|
||||
$format_string
|
||||
}
|
||||
|
@ -38,5 +38,5 @@ def env_log_short_prefix [] {
|
||||
|
||||
#[test]
|
||||
def env_log_format [] {
|
||||
assert equal $env.LOG_FORMAT $"%ANSI_START%%DATE%|%LEVEL%|(ansi u)%MSG%%ANSI_STOP%"
|
||||
assert equal $env.NU_LOG_FORMAT $"%ANSI_START%%DATE%|%LEVEL%|(ansi u)%MSG%%ANSI_STOP%"
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user