How suitable is Elixir for a CLI application?

maybe I should be more specific about the different points:

ideally a static build with a single binary.

Not generally possible. If you’re okay with a zipped artifact that decompresses into a directory, I would argue that deployment with Elixir as a client application in theory could be easier, than say python, but I have not heard of anyone who has done this.

packing everything inside like the Erlang VM…

Releases (zipped directory) do this. But you must know a considerable amount about your target environment for this to work successfully.

Protecting the source code is also desirable.

This is probably a show-stopper.

Other concerns, if you are expecting a responsive cli app (think like grep) where you might be integrating it as a part of a toolchain that runs very quickly (like generating tab-completion suggestions on a command line), this is not going to be feasible. But if you’re building something where it is going to do something necessarily long-running (like fetching files over the internet) it’s not the worst. I deployed an internal CLI tool once that concurrently-downloaded files from dropbox, S3, box, gcloud… but this was internal and not meant for customer distribution, so realistically it only had to work on one flavor of MacOS, and one flavor of linux.

Also, the erlang vm will default to hogging as many processes as there are CPUs on your system, so you may want to think about that too.