Hello folks 👋

I was making a tweak to Mix.Shell.IO.yes?/1 a while back and it occurred to 
me that it would also nice to have a password function, much the same as 
Mix.Shell.IO.prompt/1 except it would hide input from the user, which I am 
sure is familiar functionality to almost every developer.

I just had some time to look into how to implement this and it seems this 
would be easy to implement by wrapping :io.get_password/1 — for example:

def password(message) do
print_app()
:io.get_password(message <> " ")
end

Of course, in saying that, would that be a counterargument for precluding 
creating this functionality at all? :D

Thanks!
Darragh

-- 
You received this message because you are subscribed to the Google Groups 
"elixir-lang-core" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to elixir-lang-core+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/elixir-lang-core/3a9f1b0e-836f-46ab-8c53-e139b9bf3453n%40googlegroups.com.

Reply via email to