From 419a0331ab6f65e7c46a1842e109664d1091827d Mon Sep 17 00:00:00 2001 From: syl20bnr Date: Fri, 29 Apr 2016 19:55:46 -0400 Subject: [PATCH] Add font-locking for report-issue-mode buffers --- core/core-spacemacs.el | 14 ++++++++------ core/templates/REPORTING.template | 11 +++++------ 2 files changed, 13 insertions(+), 12 deletions(-) diff --git a/core/core-spacemacs.el b/core/core-spacemacs.el index 0526252ab..6c0b086e2 100644 --- a/core/core-spacemacs.el +++ b/core/core-spacemacs.el @@ -270,7 +270,7 @@ defer call using `spacemacs-post-user-config-hook'." (buffer-substring-no-properties (point-min) (min (point-max) 1000))) - "BACKTRACE IF RELEVANT")) + "<>")) (last-keys (if (and arg (y-or-n-p (concat "Do you really want to " "include your last pressed keys? It " @@ -301,12 +301,14 @@ that the issue has been created successfully, you can close this buffer. Markdown syntax is supported in this buffer. \\{spacemacs/report-issue-mode-map} -") +" + (font-lock-add-keywords 'spacemacs/report-issue-mode + '(("\\(<<.*?>>\\)" . 'font-lock-comment-face)))) -(define-key - spacemacs/report-issue-mode-map - (kbd "C-c C-c") - 'spacemacs//report-issue-done) +(define-key spacemacs/report-issue-mode-map + (kbd "C-c C-c") 'spacemacs//report-issue-done) +(define-key spacemacs/report-issue-mode-map + (kbd "C-c C-k") 'kill-buffer) (with-eval-after-load 'bind-map (spacemacs/set-leader-keys-for-major-mode 'spacemacs/report-issue-mode diff --git a/core/templates/REPORTING.template b/core/templates/REPORTING.template index 8bcafff2d..aca771c0a 100644 --- a/core/templates/REPORTING.template +++ b/core/templates/REPORTING.template @@ -1,19 +1,18 @@ - +<> #### Description -DESCRIPTION OF THE PROBLEM +<> #### Reproduction guide - Start Emacs -- REPRODUCTION STEPS +- <> *Observed behaviour:* -DESCRIPTION OF THE OBSERVED BEHAVIOUR +<> *Expected behaviour:* -DESCRIPTION OF THE EXPECTED BEHAVIOUR +<> (%LAST_KEYS%) - %SYSTEM_INFO% #### Backtrace