version bump to 1.2.9.739

- fixing minor bugs in the code
- enabled exp RightSidebar Transition Animations
 - enabled exp Remote Downloads
This commit is contained in:
amd64fox
2023-04-07 14:29:50 +03:00
parent ec7ca038b4
commit 01b77a12be
2 changed files with 43 additions and 28 deletions

View File

@@ -263,7 +263,7 @@ $win8 = $win_os -match "\windows 8\b"
# Recommended version for Win 10-12 # Recommended version for Win 10-12
if ($win10 -or $win11 -or $win12) { if ($win10 -or $win11 -or $win12) {
$onlineFull = "1.2.8.923.g4f94bf0d-1195" $onlineFull = "1.2.9.739.g0da2e75a-104"
} }
# Recommended version for Win 7-8.1 # Recommended version for Win 7-8.1
else { else {
@@ -360,7 +360,6 @@ catch {
catch { } catch { }
} }
function incorrectValue { function incorrectValue {
Write-Host ($lang).Incorrect"" -ForegroundColor Red -NoNewline Write-Host ($lang).Incorrect"" -ForegroundColor Red -NoNewline
@@ -375,22 +374,22 @@ function incorrectValue {
Clear-Host Clear-Host
} }
function unlockFolder { function Unlock-Folder {
$blockFileUpdate = "$env:LOCALAPPDATA\Spotify\Update"
$ErrorActionPreference = 'SilentlyContinue' if (Test-Path $blockFileUpdate -PathType Container) {
$block_File_update = "$env:LOCALAPPDATA\Spotify\Update" $folderUpdateAccess = Get-Acl $blockFileUpdate
$Check_folder = Get-ItemProperty -Path $block_File_update | Select-Object Attributes $hasDenyAccessRule = $false
$folder_update_access = Get-Acl $block_File_update
# Check folder Update if it exists foreach ($accessRule in $folderUpdateAccess.Access) {
if ($Check_folder -match '\bDirectory\b') { if ($accessRule.AccessControlType -eq 'Deny') {
$hasDenyAccessRule = $true
$folderUpdateAccess.RemoveAccessRule($accessRule)
}
}
# If the rights of the Update folder are blocked, then unblock if ($hasDenyAccessRule) {
if ($folder_update_access.AccessToString -match 'Deny') { Set-Acl $blockFileUpdate $folderUpdateAccess
($ACL = Get-Acl $block_File_update).access | ForEach-Object {
$Users = $_.IdentityReference
$ACL.PurgeAccessRules($Users) }
$ACL | Set-Acl $block_File_update
} }
} }
} }
@@ -514,8 +513,7 @@ function DesktopFolder {
return $desktop_folder return $desktop_folder
} }
Stop-Process -Name Spotify taskkill /f /im Spotify.exe /t > $null 2>&1
# Remove Spotify Windows Store If Any # Remove Spotify Windows Store If Any
if ($win10 -or $win11 -or $win8_1 -or $win8 -or $win12) { if ($win10 -or $win11 -or $win8_1 -or $win8 -or $win12) {
@@ -587,8 +585,8 @@ $spotifyInstalled = (Test-Path -LiteralPath $spotifyExecutable)
if ($spotifyInstalled) { if ($spotifyInstalled) {
# Check version Spotify offline # Check version Spotify offline
$offline = (Get-Item $spotifyExecutable).VersionInfo.FileVersion $offline = (Get-Item $spotifyExecutable).VersionInfo.FileVersion
# Version comparison # Version comparison
# converting strings to arrays of numbers using the -split operator and a ForEach-Object loop # converting strings to arrays of numbers using the -split operator and a ForEach-Object loop
@@ -644,7 +642,7 @@ $offline = (Get-Item $spotifyExecutable).VersionInfo.FileVersion
if ($confirm_spoti_recomended_over) { $ch = 'n' } if ($confirm_spoti_recomended_over) { $ch = 'n' }
if ($ch -eq 'y') { if ($ch -eq 'y') {
Write-Host ($lang).DelOld`n Write-Host ($lang).DelOld`n
unlockFolder Unlock-Folder | Out-Null
cmd /c $spotifyExecutable /UNINSTALL /SILENT cmd /c $spotifyExecutable /UNINSTALL /SILENT
wait-process -name SpotifyUninstall wait-process -name SpotifyUninstall
Start-Sleep -Milliseconds 200 Start-Sleep -Milliseconds 200
@@ -735,7 +733,7 @@ $offline = (Get-Item $spotifyExecutable).VersionInfo.FileVersion
if ($confirm_spoti_recomended_over) { $ch = 'n' } if ($confirm_spoti_recomended_over) { $ch = 'n' }
if ($ch -eq 'y') { if ($ch -eq 'y') {
Write-Host ($lang).DelNew`n Write-Host ($lang).DelNew`n
unlockFolder Unlock-Folder | Out-Null
cmd /c $spotifyExecutable /UNINSTALL /SILENT cmd /c $spotifyExecutable /UNINSTALL /SILENT
wait-process -name SpotifyUninstall wait-process -name SpotifyUninstall
Start-Sleep -Milliseconds 200 Start-Sleep -Milliseconds 200
@@ -767,9 +765,9 @@ if (-not $spotifyInstalled -or $upgrade_client) {
# Delete old version files of Spotify before installing, leave only profile files # Delete old version files of Spotify before installing, leave only profile files
$ErrorActionPreference = 'SilentlyContinue' $ErrorActionPreference = 'SilentlyContinue'
Stop-Process -Name Spotify taskkill /f /im Spotify.exe /t > $null 2>&1
Start-Sleep -Milliseconds 600 Start-Sleep -Milliseconds 600
unlockFolder Unlock-Folder | Out-Null
Start-Sleep -Milliseconds 200 Start-Sleep -Milliseconds 200
Get-ChildItem $spotifyDirectory -Exclude 'Users', 'prefs', 'cache' | Remove-Item -Recurse -Force Get-ChildItem $spotifyDirectory -Exclude 'Users', 'prefs', 'cache' | Remove-Item -Recurse -Force
Start-Sleep -Milliseconds 200 Start-Sleep -Milliseconds 200
@@ -784,7 +782,8 @@ if (-not $spotifyInstalled -or $upgrade_client) {
Start-Process -FilePath explorer.exe -ArgumentList $PWD\SpotifySetup.exe Start-Process -FilePath explorer.exe -ArgumentList $PWD\SpotifySetup.exe
while (-not (get-process | Where-Object { $_.ProcessName -eq 'SpotifySetup' })) {} while (-not (get-process | Where-Object { $_.ProcessName -eq 'SpotifySetup' })) {}
wait-process -name SpotifySetup wait-process -name SpotifySetup
Stop-Process -Name Spotify taskkill /f /im Spotify.exe /t > $null 2>&1
# Upgrade check version Spotify offline # Upgrade check version Spotify offline
$offline = (Get-Item $spotifyExecutable).VersionInfo.FileVersion $offline = (Get-Item $spotifyExecutable).VersionInfo.FileVersion

View File

@@ -956,6 +956,22 @@
}, },
"match": "(Enables the \"Your DJ\" feature',default:)(!1)", "match": "(Enables the \"Your DJ\" feature',default:)(!1)",
"replace": "$1true" "replace": "$1true"
},
"RightSidebarAnimations": {
"version": {
"from": "1.2.8",
"do": ""
},
"match": "(Enable the slide-in/out transition on the right sidebar\",default:)(!1)",
"replace": "$1true"
},
"RemoteDownloads": {
"version": {
"from": "1.2.8",
"do": ""
},
"match": "(Enable the slide-in/out transition on the right sidebar\",default:)(!1)",
"replace": "$1true"
} }
} }
} }