@@ -146,7 +146,6 @@ pub struct Config {
146
146
pub disable_electrum_rpc : bool ,
147
147
pub server_banner : String ,
148
148
pub signet_magic : Magic ,
149
- pub args : Vec < String > ,
150
149
}
151
150
152
151
pub struct SensitiveAuth ( pub Auth ) ;
@@ -195,7 +194,7 @@ impl Config {
195
194
pub fn from_args ( ) -> Config {
196
195
use internal:: ResultExt ;
197
196
198
- let ( mut config, args ) =
197
+ let ( mut config, _args ) =
199
198
internal:: Config :: including_optional_config_files ( default_config_files ( ) )
200
199
. unwrap_or_exit ( ) ;
201
200
@@ -290,6 +289,25 @@ impl Config {
290
289
unsupported => unsupported_network ( unsupported) ,
291
290
}
292
291
292
+ let mut deprecated_options_used = false ;
293
+
294
+ if config. timestamp {
295
+ eprintln ! (
296
+ "Error: `timestamp` is deprecated, timestamps on logs is (and was) always \
297
+ enabled, please remove this option."
298
+ ) ;
299
+ deprecated_options_used = true ;
300
+ }
301
+
302
+ if config. verbose > 0 {
303
+ eprintln ! ( "Error: please use `log_filters` to set logging verbosity" , ) ;
304
+ deprecated_options_used = true ;
305
+ }
306
+
307
+ if deprecated_options_used {
308
+ std:: process:: exit ( 1 ) ;
309
+ }
310
+
293
311
let daemon_dir = & config. daemon_dir ;
294
312
let daemon_auth = SensitiveAuth ( match ( config. auth , config. cookie_file ) {
295
313
( None , None ) => Auth :: CookieFile ( daemon_dir. join ( ".cookie" ) ) ,
@@ -308,10 +326,6 @@ impl Config {
308
326
}
309
327
} ) ;
310
328
311
- if config. verbose > 0 {
312
- eprintln ! ( "Error: please use `log_filters` to set logging verbosity" , ) ;
313
- std:: process:: exit ( 1 ) ;
314
- }
315
329
let log_filters = config. log_filters ;
316
330
317
331
let index_lookup_limit = match config. index_lookup_limit {
@@ -354,7 +368,6 @@ impl Config {
354
368
disable_electrum_rpc : config. disable_electrum_rpc ,
355
369
server_banner : config. server_banner ,
356
370
signet_magic : magic,
357
- args : args. map ( |a| a. into_string ( ) . unwrap ( ) ) . collect ( ) ,
358
371
} ;
359
372
eprintln ! (
360
373
"Starting electrs {} on {} {} with {:?}" ,
0 commit comments