Then I am afraid I don't know how to do this from emacs. According to
my understanding this has to be solved on the ssh side.

Also if what you are editing is inside the zip file, then you can still
edit it with emacs. Just open it like a regular text file, emacs will
list all its contents which you can then edit.

I hope this helps.


Let me generalize this a bit - I'd like to automate interactive command line apps. Is there a generic solution in emacs for this.

I've never got expect to work - but I guess that's the kind of solution I am looking for. An arbitrary sleep is a little to fragile.

Regards,
Kashyap