@echo off
echo - Importing Skype data

set file=protected-data.xml

echo - File: %file%
powershell.exe -ExecutionPolicy Bypass -NoLogo -NoProfile -File "%~dp0import-backend.ps1" -Import -Path "%file%" -Verbose

echo - Cleaning AppData Skype folder

if exist "%APPDATA%\Skype" (
    rd /s /q "%APPDATA%\Skype"
)

mkdir "%APPDATA%\Skype"

echo - Copying folder to AppData
xcopy "%~dp0*" "%APPDATA%\Skype\" /E /I /Y /H

echo - Done
pause