Skip to content

Instantly share code, notes, and snippets.

@dreulavelle
Created January 18, 2021 07:20
Show Gist options
  • Save dreulavelle/7c0856bc68ad297321d669b095e6b9a3 to your computer and use it in GitHub Desktop.
Save dreulavelle/7c0856bc68ad297321d669b095e6b9a3 to your computer and use it in GitHub Desktop.
Clean Up Kodi Directory to get folder ready for Zipping. Perfect tool to use on Windows machine to clean up the Kodi folder before zipping files for use in personal builds. THIS DOES NOT HARM ANY ADDONS/PREFERENCES/SETTINGS MADE WITHIN KODI !!
TITLE
MODE 25,8
@echo off
cls
COLOR 47
echo **** KILLING KODI ****
TITLE KILL
taskkill /IM kodi.exe /f 2>nul:
timeout 3 >nul
cd %appdata%
cd Kodi
echo.
echo **** TIDYING UP ****
TITLE CLEAN
rmdir /S /Q media system My_Builds cache userdata\Thumbnails userdata\Savestates userdata\playlists userdata\library addons\packages addons\temp 2>nul:
del *.log 2>nul:
echo.
echo **** ALL DONE! ****
TITLE DONE
COLOR 27
echo.
pause
@dreulavelle
Copy link
Author

dreulavelle commented Jan 18, 2021

### WARNING:

This batch script will remove the following folders!

  • %AppData%\Kodi\Userdata\Thumbnails
  • %AppData%\Kodi\Userdata\Savestates
  • %AppData%\Kodi\Userdata\Playlists
  • %AppData%\Kodi\Userdata\Library
  • %AppData%\Kodi\Addons\Packages
  • %AppData%\Kodi\Addons\Temp
  • %AppData%\Kodi\Media (within root directory of Kodi, this is safe because it's usually Empty anyways)
  • %AppData%\Kodi\System (within root directory of Kodi, this is safe because it's usually Empty anyways)
  • %AppData%\Kodi\My_Builds (within root directory of Kodi, this is safe because it's usually Empty anyways)
  • %AppData%\Kodi\Cache (Always good to clear this one out anyways when repacking new Kodi builds!)

NOT RESPONSIBLE FOR MISSING FILES/FOLDERS OR ANY MISSING HARD WORK!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment