Skip to content

Commit 988f14a

Browse files
committed
chore(notify): sort logging macros and NotificationLevel on verbosity
50216ad 'reorder'
1 parent 2c4f986 commit 988f14a

File tree

2 files changed

+9
-9
lines changed

2 files changed

+9
-9
lines changed

src/cli/log.rs

+8-8
Original file line numberDiff line numberDiff line change
@@ -18,24 +18,24 @@ use opentelemetry_sdk::trace::Tracer;
1818

1919
use crate::{currentprocess::Process, utils::notify::NotificationLevel};
2020

21-
macro_rules! warn {
22-
( $ ( $ arg : tt ) * ) => ( ::tracing::warn ! ( $ ( $ arg ) * ) )
21+
macro_rules! debug {
22+
( $ ( $ arg : tt ) * ) => ( ::tracing::trace ! ( $ ( $ arg ) * ) )
2323
}
2424

25-
macro_rules! err {
26-
( $ ( $ arg : tt ) * ) => ( ::tracing::error ! ( $ ( $ arg ) * ) )
25+
macro_rules! verbose {
26+
( $ ( $ arg : tt ) * ) => ( ::tracing::debug ! ( $ ( $ arg ) * ) )
2727
}
2828

2929
macro_rules! info {
3030
( $ ( $ arg : tt ) * ) => ( ::tracing::info ! ( $ ( $ arg ) * ) )
3131
}
3232

33-
macro_rules! verbose {
34-
( $ ( $ arg : tt ) * ) => ( ::tracing::debug ! ( $ ( $ arg ) * ) )
33+
macro_rules! warn {
34+
( $ ( $ arg : tt ) * ) => ( ::tracing::warn ! ( $ ( $ arg ) * ) )
3535
}
3636

37-
macro_rules! debug {
38-
( $ ( $ arg : tt ) * ) => ( ::tracing::trace ! ( $ ( $ arg ) * ) )
37+
macro_rules! err {
38+
( $ ( $ arg : tt ) * ) => ( ::tracing::error ! ( $ ( $ arg ) * ) )
3939
}
4040

4141
pub fn tracing_subscriber(process: Process) -> impl tracing::Subscriber {

src/utils/notify.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,11 @@ use tracing::Level;
44

55
#[derive(Debug)]
66
pub(crate) enum NotificationLevel {
7+
Debug,
78
Verbose,
89
Info,
910
Warn,
1011
Error,
11-
Debug,
1212
}
1313

1414
impl fmt::Display for NotificationLevel {

0 commit comments

Comments
 (0)