File tree Expand file tree Collapse file tree 3 files changed +12
-3
lines changed Expand file tree Collapse file tree 3 files changed +12
-3
lines changed Original file line number Diff line number Diff line change 68
68
utils .KeyStoreDirFlag ,
69
69
utils .ExternalSignerFlag ,
70
70
utils .NoUSBFlag ,
71
+ utils .USBFlag ,
71
72
utils .SmartCardDaemonPathFlag ,
72
73
utils .EthashCacheDirFlag ,
73
74
utils .EthashCachesInMemoryFlag ,
Original file line number Diff line number Diff line change @@ -37,7 +37,7 @@ var AppHelpFlagGroups = []flags.FlagGroup{
37
37
utils .DataDirFlag ,
38
38
utils .AncientFlag ,
39
39
utils .KeyStoreDirFlag ,
40
- utils .NoUSBFlag ,
40
+ utils .USBFlag ,
41
41
utils .SmartCardDaemonPathFlag ,
42
42
utils .NetworkIdFlag ,
43
43
utils .GoerliFlag ,
@@ -219,6 +219,7 @@ var AppHelpFlagGroups = []flags.FlagGroup{
219
219
{
220
220
Name : "ALIASED (deprecated)" ,
221
221
Flags : append ([]cli.Flag {
222
+ utils .NoUSBFlag ,
222
223
utils .LegacyRPCEnabledFlag ,
223
224
utils .LegacyRPCListenAddrFlag ,
224
225
utils .LegacyRPCPortFlag ,
Original file line number Diff line number Diff line change @@ -119,7 +119,11 @@ var (
119
119
}
120
120
NoUSBFlag = cli.BoolFlag {
121
121
Name : "nousb" ,
122
- Usage : "Disables monitoring for and managing USB hardware wallets" ,
122
+ Usage : "Disables monitoring for and managing USB hardware wallets (deprecated)" ,
123
+ }
124
+ USBFlag = cli.BoolFlag {
125
+ Name : "usb" ,
126
+ Usage : "Enable monitoring and management of USB hardware wallets" ,
123
127
}
124
128
SmartCardDaemonPathFlag = cli.StringFlag {
125
129
Name : "pcscdpath" ,
@@ -1225,8 +1229,11 @@ func SetNodeConfig(ctx *cli.Context, cfg *node.Config) {
1225
1229
if ctx .GlobalIsSet (LightKDFFlag .Name ) {
1226
1230
cfg .UseLightweightKDF = ctx .GlobalBool (LightKDFFlag .Name )
1227
1231
}
1232
+ if ctx .GlobalIsSet (USBFlag .Name ) {
1233
+ cfg .NoUSB = ! ctx .GlobalBool (USBFlag .Name )
1234
+ }
1228
1235
if ctx .GlobalIsSet (NoUSBFlag .Name ) {
1229
- cfg . NoUSB = ctx . GlobalBool ( NoUSBFlag . Name )
1236
+ log . Warn ( "Option nousb is deprecated and USB is deactivated by default. Use --usb to enable" )
1230
1237
}
1231
1238
if ctx .GlobalIsSet (InsecureUnlockAllowedFlag .Name ) {
1232
1239
cfg .InsecureUnlockAllowed = ctx .GlobalBool (InsecureUnlockAllowedFlag .Name )
You can’t perform that action at this time.
0 commit comments