set tc=%commander_path%
"%tc%"\addons\tcmc cmcm_UnloadPlugins
cd %temp%
if exist uninstall.tc.bat null
"%tc%"\tools\nircmd killprocess totalcmd64
"%tc%"\tools\nircmd killprocess nircmd
"%tc%"\tools\nircmd killprocess akelpad
"%tc%"\tools\nircmd killprocess newfile
"%tc%"\tools\nircmd execmd del "~$folder.desktop$\total commander.lnk" 2>nul
rd "%temp%"\_tc* /q /s
del "%temp%"\cmd*.tmp
reg delete HKCU\Software\Akelsoft /f >nul 2>nul
"%tc%"\tools\nircmd waitprocess totalcmd64
rd "%tc%" /q /s
del %0
else
copy %0 %temp%
start "uninstall.tc.bat"
exit