Skip to content

Copy code for discord #672

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
DarwinWasWrong opened this issue Dec 9, 2021 · 1 comment
Closed

Copy code for discord #672

DarwinWasWrong opened this issue Dec 9, 2021 · 1 comment
Assignees
Labels
conclusion: resolved Issue was resolved topic: code Related to content of the project itself type: enhancement Proposed improvement

Comments

@DarwinWasWrong
Copy link

DarwinWasWrong commented Dec 9, 2021

In the edit menu, there is an option to copy code for forum. Control shift C
this places [CODE] and [/CODE] around the copied code.
This is very handy for posting code to the forum.

Is it possible to add either a copy code for discord or have the code block specification adjustable in setup

On discord, the code surrounds are three back ticks, the word arduino then three back ticks closing off the block
``` arduino ```

The use of the arduino keyword colors the code

image

@DarwinWasWrong DarwinWasWrong added the type: enhancement Proposed improvement label Dec 9, 2021
@per1234
Copy link
Contributor

per1234 commented Dec 9, 2021

Hi @DarwinWasWrong. Fortunately, the switch to using Discourse for the Arduino Forum software last spring introduced support for the same Markdown markup language used by Discord, GitHub, Stack Exchange, etc. This means that a single menu item can serve for all these communication channels used by the Arduino community.

It was only necessary to change from using BBCode (which is still supported as an alternative markup language on the forum) to Markdown in the copied text. That work has already been done in Arduino IDE 2.x

Related: #491

@per1234 per1234 closed this as completed Dec 9, 2021
@per1234 per1234 added conclusion: resolved Issue was resolved topic: code Related to content of the project itself labels Dec 9, 2021
@per1234 per1234 self-assigned this Dec 14, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
conclusion: resolved Issue was resolved topic: code Related to content of the project itself type: enhancement Proposed improvement
Projects
None yet
Development

No branches or pull requests

2 participants