How to Run The Zip Command Line Utility With a Password as a Shell Script?

I'm trying to run the zip utility via Execute Shell Script, but I cannot get the syntax right. Please help.


ZIP with password.kmmacros (2.2 KB)

The -e will prompt you to enter a password. There's no way to do that when you're using Keyboard Maestro.

You could use --password but that is insecure, and storing it in Keyboard Maestro is also insecure.

I suppose you could prompt for a password into a Keyboard Maestro local variable and use that, knowing it would be discarded as soon as the macro finishes. If you're the only user of your Mac, that's not horribly insecure.

3 Likes

If you're going to do this often and want to reuse the same password you can put it in the KeyChain and access it with Keyboard Maestro.

image

-Chris

3 Likes