The instructions are described here: [HOW TO] CLI install method
You can revert back to the app store version at any time be reinstalling that version from the app store.
I will need some time to make the necessary changes which I want to test and I will send you a link to a zip file containing the debug version of the app. After you install it using the homey app install
command you just need to keep an eye out on the memory usage and see if it still increases.
[EDIT]
Also a question to narrow things down, do you use the Update Firmware
action card in any of your flows?