From f7a27a65d3171bfd09b8fef16e1474756bee1240 Mon Sep 17 00:00:00 2001 From: Troy Hinckley Date: Fri, 17 May 2024 14:10:34 -0500 Subject: [PATCH] Spellcheck warnings (#14) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * Use correct quotes in rust-spellcheck.el docstrings Fixes In toplevel form: rustic-spellcheck.el:18:9: Warning: defvar ‘rustic-spellcheck-arguments’ docstring has wrong usage of unescaped single quotes (use \=' or different quoting such as `...') In rustic-cargo-spellcheck: rustic-spellcheck.el:92:2: Warning: docstring has wrong usage of unescaped single quotes (use \=' or different quoting such as `...') In rustic-cargo-spellcheck-command: rustic-spellcheck.el:106:2: Warning: docstring has wrong usage of unescaped single quotes (use \=' or different quoting such as `...') In rustic-cargo-spellcheck-rerun: rustic-spellcheck.el:117:2: Warning: docstring has wrong usage of unescaped single quotes (use \=' or different quoting such as `...') * Remove unused variable in rustic-cargo-spellcheck-command Fixes: rustic-spellcheck.el:110:11: Warning: Unused lexical variable ‘spellcheck-command’ --------- Co-authored-by: Ola Nilsson --- rustic-spellcheck.el | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/rustic-spellcheck.el b/rustic-spellcheck.el index 7662e480..9bc8cc02 100644 --- a/rustic-spellcheck.el +++ b/rustic-spellcheck.el @@ -16,7 +16,7 @@ "Buffer name for spellcheck buffers.") (defvar rustic-spellcheck-arguments "" - "Holds arguments for 'cargo spellcheck', similar to `compilation-arguments`.") + "Holds arguments for `cargo spellcheck', similar to `compilation-arguments`.") (defvar rustic-cargo-spellcheck-mode-map (let ((map (make-sparse-keymap))) @@ -90,7 +90,7 @@ Error matching regexes from compile.el are removed." ;;;###autoload (defun rustic-cargo-spellcheck (&optional arg) - "Run 'cargo spellcheck'. + "Run `cargo spellcheck'. If ARG is not nil, use value as argument and store it in `rustic-spellcheck-arguments'. When calling this function from @@ -104,10 +104,9 @@ If ARG is not nil, use value as argument and store it in (t "")))) (defun rustic-cargo-spellcheck-command (&optional spellcheck-args) - "Start compilation process for 'cargo spellcheck' with optional SPELLCHECK-ARGS." + "Start compilation process for `cargo spellcheck' with optional SPELLCHECK-ARGS." (let* ((command (list (rustic-cargo-bin) "spellcheck")) (c (append command (split-string (if spellcheck-args spellcheck-args "")))) - (spellcheck-command (string-join c " ")) (buf rustic-spellcheck-buffer-name) (proc rustic-spellcheck-process-name) (mode 'rustic-cargo-spellcheck-mode)) @@ -115,7 +114,7 @@ If ARG is not nil, use value as argument and store it in ;;;###autoload (defun rustic-cargo-spellcheck-rerun () - "Run 'cargo spellcheck' with `rustic-spellcheck-arguments'." + "Run `cargo spellcheck' with `rustic-spellcheck-arguments'." (interactive) (rustic-cargo-spellcheck-command rustic-spellcheck-arguments))