Refactoring for ThemeInstaller and ThemeCompiler