Disclaimer: not only am I new to writing discourse plugins, this was written hastily with the intention to polish it later. Use at your own risk!
A Discourse Plugin (built on top of discourse-awesome-bbcodes) that adds custom BBCode tags for Doom Emacs' Discourse. These tags are:
-
[dump]...[/dump]
--- Useful for large text dumps that shouldn't be indexed by the search engine. Our github issue tracker had a serious issue with system information polluting the search results. -
[float=left]...[/float]
or[float=right]...[/float]
--- used to float content to the left or right. -
[clear][/clear]
--- used to clear floated content. -
[kbd command=+ivy/switch-workspace-buffer alt="C-x C-b,SPC b B]SPC b b[/kbd]
--- syntax sugar for key sequences. Will later be improved to display commands and alternative key sequences on mouseover. -
[notice]...[/notice]
--- creates a notice modal (a blockquote). Uses the first emoji in the first element as the notice's icon, and appends anotice-EMOJINAME
class to the enclosing blockquote. -
[tabs id=ID title=TITLE]...[/tabs]
--- Tabbed sections of content. Use[tab=ID]...[/tab]
inside. -
[[...]]
syntax for auto-linking:- Github issue references:
[[#123]]
,[[doom-emacs/#1234]]
,[[hlissner/doom-emacs#1234]]
- Links to Doom module docs or a particular module flag's docs:
[[:lang]]
,[[:lang rust]]
,[[:lang rust +lsp]]
- Packages:
[[package:evil]]
,[[p:evil]]
,[[p:rustic-mode]]
- Functions/Macros:
[[fn:evil-join]]
,[[fn:after!]]
,[[fn:add-hook]]
- Variables:
[[var:evil-join]]
,[[var:after!]]
,[[var:add-hook]]
- Faces:
[[face:org-level-2]]
,[[face:font-lock-comment-face]]
- Github issue references:
- Add the plugin's repo url to your container's yml config file
hooks:
after_code:
- exec:
cd: $home/plugins
cmd:
# ...
- git clone https://github.com/doomemacs/discourse-custom-bbcodes.git
- Rebuild the container
cd /var/discourse
git pull
./launcher rebuild app
- discourse-awesome-bbcodes was used as a basis for this plugin (by David Montoya and Charles-Pierre Astolfi)