@@ -437,44 +437,44 @@ function Add-Config {
437
437
}
438
438
439
439
function Add-DefaultConfig {
440
- # If user-level SCOOP env not defined, save to rootPath
440
+ # If user-level SCOOP env not defined, save to root_path
441
441
if (! (Get-Env ' SCOOP' )) {
442
442
if ($SCOOP_DIR -ne " $env: USERPROFILE \scoop" ) {
443
- Write-Verbose " Adding config rootPath : $SCOOP_DIR "
444
- Add-Config - Name ' rootPath ' - Value $SCOOP_DIR | Out-Null
443
+ Write-Verbose " Adding config root_path : $SCOOP_DIR "
444
+ Add-Config - Name ' root_path ' - Value $SCOOP_DIR | Out-Null
445
445
}
446
446
}
447
447
448
448
# Use system SCOOP_GLOBAL, or set system SCOOP_GLOBAL
449
- # with $env:SCOOP_GLOBAL if RunAsAdmin, otherwise save to globalPath
449
+ # with $env:SCOOP_GLOBAL if RunAsAdmin, otherwise save to global_path
450
450
if (! (Get-Env ' SCOOP_GLOBAL' - global)) {
451
451
if ((Test-IsAdministrator ) -and $env: SCOOP_GLOBAL ) {
452
452
Write-Verbose " Setting System Environment Variable SCOOP_GLOBAL: $env: SCOOP_GLOBAL "
453
453
[Environment ]::SetEnvironmentVariable(' SCOOP_GLOBAL' , $env: SCOOP_GLOBAL , ' Machine' )
454
454
} else {
455
455
if ($SCOOP_GLOBAL_DIR -ne " $env: ProgramData \scoop" ) {
456
- Write-Verbose " Adding config globalPath : $SCOOP_GLOBAL_DIR "
457
- Add-Config - Name ' globalPath ' - Value $SCOOP_GLOBAL_DIR | Out-Null
456
+ Write-Verbose " Adding config global_path : $SCOOP_GLOBAL_DIR "
457
+ Add-Config - Name ' global_path ' - Value $SCOOP_GLOBAL_DIR | Out-Null
458
458
}
459
459
}
460
460
}
461
461
462
462
# Use system SCOOP_CACHE, or set system SCOOP_CACHE
463
- # with $env:SCOOP_CACHE if RunAsAdmin, otherwise save to cachePath
463
+ # with $env:SCOOP_CACHE if RunAsAdmin, otherwise save to cache_path
464
464
if (! (Get-Env ' SCOOP_CACHE' - global)) {
465
465
if ((Test-IsAdministrator ) -and $env: SCOOP_CACHE ) {
466
466
Write-Verbose " Setting System Environment Variable SCOOP_CACHE: $env: SCOOP_CACHE "
467
467
[Environment ]::SetEnvironmentVariable(' SCOOP_CACHE' , $env: SCOOP_CACHE , ' Machine' )
468
468
} else {
469
469
if ($SCOOP_CACHE_DIR -ne " $SCOOP_DIR \cache" ) {
470
- Write-Verbose " Adding config cachePath : $SCOOP_CACHE_DIR "
471
- Add-Config - Name ' cachePath ' - Value $SCOOP_CACHE_DIR | Out-Null
470
+ Write-Verbose " Adding config cache_path : $SCOOP_CACHE_DIR "
471
+ Add-Config - Name ' cache_path ' - Value $SCOOP_CACHE_DIR | Out-Null
472
472
}
473
473
}
474
474
}
475
475
476
- # save current datatime to lastUpdate
477
- Add-Config - Name ' lastUpdate ' - Value ([System.DateTime ]::Now.ToString(' o' )) | Out-Null
476
+ # save current datatime to last_update
477
+ Add-Config - Name ' last_update ' - Value ([System.DateTime ]::Now.ToString(' o' )) | Out-Null
478
478
}
479
479
480
480
function Install-Scoop {
0 commit comments