Closed mcint closed 4 years ago
I've googled a little bit, and it looks like you are right @terminalforlife and there is no point of removing space here, except that one, that in this form it is (by chance) not getting interpreted by shell, and so it works properly, and that's why this illusion appears that the space is important for say
itself (and it is not).
say
accepts option ?
, and it means "list the voices".
If ?
is not escaped, and there are single-letter files in the current directory, the ?
is expanded, and it does not work properly. If in the directory would be some file called started with-v
, e.g. -victory-
the no-space variant would not work either.
So I think the best option would be to add the space back and explicitly escape the ?
mark:
say -v '?'
What do you think?
That would be my approach, too. A lot of my terminal programs used to have ?
as a possible help/usage argument (for old-schoolers), so I'd have assumed users would go with the escape as well. I'm surprised say
is using a q-mark like that.
Good call, thanks. I appreciate not having to remember the special case behavior. I'll push a replacement quoted (or escaped) commit.
Nice. What does the
?
do withsay
? I'm not familiar withsay
, but it seems to be likeespeak
. The question-mark is a special character in Shell-land, so wouldn't it be interpreted in some unwanted way? Could it be typo?