Fix the parentheses in the recovery script

Co-Authored-By: Claude Code <noreply@anthropic.com>
This commit is contained in:
Zebreus 2026-10-25 13:42:21 +01:00
commit ac98212fa2

View file

@ -14,9 +14,8 @@ if not exist C:\Users\Administrator\.ssh mkdir C:\Users\Administrator\.ssh
REM The user owns their .ssh, so that they can add keys of their own. REM The user owns their .ssh, so that they can add keys of their own.
for /f "tokens=5" %%i in ('findstr /b "root:" C:\msys2\etc\passwd') do set SID=%%i for /f "tokens=5" %%i in ('findstr /b "root:" C:\msys2\etc\passwd') do set SID=%%i
set SID=!SID:*,=! set SID=!SID:*,=!
if defined SID ( if not defined SID goto :done
icacls C:\msys2\home\root\.ssh /grant *!SID!:(OI)(CI)F /t icacls C:\msys2\home\root\.ssh /grant *!SID!:(OI)(CI)F /t
icacls C:\msys2\home\root\.ssh /setowner *!SID! icacls C:\msys2\home\root\.ssh /setowner *!SID!
) :done
echo The SSH access is back. echo The SSH access is back.