Steps for getting manual hot-deploy for Liferay:
- Set developer mode to active by adding
-Dexternal-properties=portal-developer.properties
in file setenv.sh (or setenv.bat on Windows) located in Liferay’s bundled Tomcat bin directory. - For CSS:
- Copy the CSS files (which should preferably be in the same directory, eg. CSS) to a directory with the same name to the following paths:
${liferay.tomcat}/webapps/${app.folder}/css
${liferay.tomcat}/webapps/${app.folder}/css/.sass_cache
${liferay.tomcat}/temp/${app.temp.folder}/css
${liferay.tomcat}/temp/${app.temp.folder}/css/.sass_cache
- Please note that if
${app.folder}
is for example my-app,${app.temp.folder}
usually has the same name prefixed by a number, eg. 10-my-app.
- Remove
${liferay.tomcat}/work/Catalina/localhost/${app.folder}
dir. - When reloading the page, Liferay will load the necessary files on the work directory and so the new styles will be used without the need to generate and deploy a new war.
- The same process can be used for jsp files ommiting the step for the .sass_cache dir.