Describe the bug
The way to add purging to a project is to add a purge.js file to the project config root as per the docs. So, naturally, to remove purging from a project, a user would think that removing purge.js would be the way to do so, but it doesn't work. If you empty the purge.js file, it creates an empty object in the purge key of the settings JSON file but it's not ideal to have an empty object even in the database.
To Reproduce
Steps to reproduce the behavior:
Create a purge.js file and add your purge logic
Run the command cht compile-app-settings
Check the app_settings.json file. A new key purge should have been minified created with the content from the purge.js.
Delete or move or rename the purge.js file.
Run the command cht-compile-app-settings
Check the app_settings.json file. The purge key still exists.
Expected behavior
When I delete or move or rename the purge.js file from the root of the project config, the settings should also remove the purge key from the JSON file.
Logs
If applicable, include the cht-conf output, server logs, and/or browser logs.
Screenshots
If applicable, add screenshots to help explain your problem.
Environment
Instance: Local
Client platform: Linux
cht-conf version: 4.1.1
cht-core version: N/A
Additional context
Add any other context about the problem here. What have you tried? Is there a workaround?
Describe the bug The way to add purging to a project is to add a
purge.js
file to the project config root as per the docs. So, naturally, to remove purging from a project, a user would think that removingpurge.js
would be the way to do so, but it doesn't work. If you empty thepurge.js
file, it creates an empty object in thepurge
key of the settings JSON file but it's not ideal to have an empty object even in the database.To Reproduce Steps to reproduce the behavior:
purge.js
file and add your purge logiccht compile-app-settings
app_settings.json
file. A new keypurge
should have been minified created with the content from thepurge.js
.purge.js
file.cht-compile-app-settings
app_settings.json
file. Thepurge
key still exists.Expected behavior When I delete or move or rename the
purge.js
file from the root of the project config, the settings should also remove thepurge
key from the JSON file.Logs If applicable, include the cht-conf output, server logs, and/or browser logs.
Screenshots If applicable, add screenshots to help explain your problem.
Environment
Additional context Add any other context about the problem here. What have you tried? Is there a workaround?