diff --git a/CHANGELOG.develop b/CHANGELOG.develop index 4ce2686b9..816d7bf01 100644 --- a/CHANGELOG.develop +++ b/CHANGELOG.develop @@ -1649,6 +1649,8 @@ Other: **** Nim - Added key binding ~SPC m h h~ to show symbol documentation (thanks to Valts Liepiņš) +- Make =spacemacs/nim-compile-run= work with current buffer file instead of + defaulting to =main.nim= (thanks to Uroš Perišić) - Replace =company-capf= with =company-nimsuggest= in =company-backends-nim-mode= to improve responsiveness (thanks to Uroš Perišić) - Declare all prefix names (='(compile goto help)=) for =nim-mode= (thanks to diff --git a/layers/+lang/nim/packages.el b/layers/+lang/nim/packages.el index 1ede6b5fc..b1fa38eb2 100644 --- a/layers/+lang/nim/packages.el +++ b/layers/+lang/nim/packages.el @@ -39,8 +39,9 @@ :config (progn (defun spacemacs/nim-compile-run () + "Compile current buffer file." (interactive) - (shell-command "nim compile --run main.nim")) + (shell-command (concat "nim compile --run " (buffer-file-name)))) (spacemacs/declare-prefix-for-mode 'nim-mode "mc" "compile") (spacemacs/declare-prefix-for-mode 'nim-mode "mg" "goto")