peter-evans / slash-command-dispatch

A GitHub action that facilitates "ChatOps" by creating repository dispatch events for slash commands
MIT License
588 stars 53 forks source link

Please support commands in inline code blocks #330

Open xaviergmail opened 8 months ago

xaviergmail commented 8 months ago

I have a command that uses star globbing (example: /e2e non-parallel-tests/*.js parallel/role-*/*.js) When writing this command outside an inline code block, the two matching stars turn it to italics as such: /e2e non-parallel-tests/.js parallel/role-/*.js.

This then prevents us from being able to copy/paste commands from previous comments for reuse.

I'd like to suggest the addition of an option to allow us to pass commands not only like this:

/command [args...]

[Rest of comment...]

but like this as well:

`/command [args...]`

[Rest of comment...]
peter-evans commented 8 months ago

Hi @xaviergmail

I understand your issue, but I don't think allowing commands in code blocks to be executable is a good approach. Most users will intuitively understand that content inside code blocks is non-executable I think. Adding this could also potentially break some users workflows.

I'll have a think if there is some other workaround to your issue.