slash-command-dispatch icon indicating copy to clipboard operation
slash-command-dispatch copied to clipboard

UX: allow spaces between `=` and param values

Open staabm opened this issue 3 years ago • 1 comments
trafficstars

sometimes when copy/pasting I end up with a chat command like /merge source= my-source target=master

notice the space before the my-source value.

IMO it would be great if the param parsing could handle this case and foregive me my copy pasting whitespaces :-)

in other words /merge source= my-source target=master should be the same thing as /merge source=my-source target=master

staabm avatar Dec 14 '21 08:12 staabm

Hi @staabm

I think allowing this will open a can of worms and make the tokeniser implementation way more complicated than it needs to be. If we allow source= my-source, then why not source =my-source?, etc., and then it gets very complicated to parse the arguments correctly.

I would like to keep the current implementation for now because it's easy to maintain and robust. However, in future I'm open to swapping out my tokeniser implementation for a well supported library if there is something suitable.

peter-evans avatar Dec 15 '21 01:12 peter-evans