Skip to content

Commit 064db72

Browse files
committed
chore: Improve warning messages
1 parent 134d408 commit 064db72

File tree

1 file changed

+11
-11
lines changed

1 file changed

+11
-11
lines changed

lisp/_prepare.el

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -2100,39 +2100,39 @@ Arguments MSG1, MSG2, MSG3 and MSG4 are conditional messages."
21002100
(when-let* (((and eask-package eask-package-desc))
21012101
(def-point (if (eask-pkg-el) "-pkg.el file" "package-file")))
21022102
(eask--check-strings
2103-
"Unmatched package name '%s'; it should be '%s'"
2103+
"Unmatched package name `%s`; it should be `%s`"
21042104
(eask-package-name) (package-desc-name eask-package-desc))
21052105
(when-let* ((ver-eask (eask-package-version))
21062106
(ver-pkg (package-desc-version eask-package-desc))
21072107
;; `package-version-join' returns only one of the possible
21082108
;; inverses, since `version-to-list' is a many-to-one operation
21092109
((not (equal (version-to-list ver-eask) ver-pkg))))
21102110
(eask--check-strings
2111-
"Unmatched version '%s'; it should be '%s'"
2111+
"Unmatched version `%s`; it should be `%s`"
21122112
ver-eask (package-version-join ver-pkg)))
21132113
(eask--check-strings
2114-
"Unmatched summary '%s'; it should be '%s'"
2114+
"Unmatched summary `%s`; it should be `%s`"
21152115
(eask-package-description) (package-desc-summary eask-package-desc))
21162116
(let ((url (eask-package-desc-url)))
21172117
(eask--check-optional
21182118
eask-website-url url
2119-
"Unmatched website URL '%s'; it should be '%s'"
2120-
(format "Unmatched website URL '%s'; add %s to %s" eask-website-url
2119+
"Unmatched website URL `%s`; it should be `%s`"
2120+
(format "Unmatched website URL `%s`; add `%s` to %s" eask-website-url
21212121
(if (string-prefix-p "-pkg.el" def-point)
21222122
(format ":url \"%s\"" eask-website-url)
21232123
(format ";; URL: %s" eask-website-url))
21242124
def-point)
2125-
(format "Unmatched website URL '%s'; add (website-url \"%s\") to Eask-file" url url)
2125+
(format "Unmatched website URL `%s`; add `(website-url \"%s\")` to Eask-file" url url)
21262126
(format "URL header is optional, but it's often recommended")))
21272127
(let ((keywords (eask-package-desc-keywords)))
21282128
(cond
21292129
((or keywords eask-keywords)
21302130
(dolist (keyword keywords)
21312131
(unless (member keyword eask-keywords)
2132-
(eask-warn "Unmatched keyword '%s'; add (keywords \"%s\") to Eask-file or consider removing it" keyword keyword)))
2132+
(eask-warn "Unmatched keyword `%s`; add `(keywords \"%s\")` to Eask-file or consider removing it" keyword keyword)))
21332133
(dolist (keyword eask-keywords)
21342134
(unless (member keyword keywords)
2135-
(eask-warn "Unmatched keyword '%s'; add %s to %s or consider removing it"
2135+
(eask-warn "Unmatched keyword `%s`; add `%s` to %s or consider removing it"
21362136
keyword
21372137
(if (string-prefix-p "-pkg.el" def-point)
21382138
(format ":keywords '(\"%s\")" keyword)
@@ -2148,10 +2148,10 @@ Arguments MSG1, MSG2, MSG3 and MSG4 are conditional messages."
21482148
(requirements (mapcar (lambda (elm) (eask-2str elm)) requirements)))
21492149
(dolist (req requirements)
21502150
(unless (member req dependencies)
2151-
(eask-warn "Unmatched dependency '%s'; add (depends-on \"%s\") to Eask-file or consider removing it" req req)))
2151+
(eask-warn "Unmatched dependency `%s`; add `(depends-on \"%s\")` to Eask-file or consider removing it" req req)))
21522152
(dolist (dep dependencies)
21532153
(unless (member dep requirements)
2154-
(eask-warn "Unmatched dependency '%s'; add (%s \"VERSION\") to %s or consider removing it" dep dep def-point))))))
2154+
(eask-warn "Unmatched dependency `%s`; add `(%s \"VERSION\")` to %s or consider removing it" dep dep def-point))))))
21552155

21562156
(add-hook 'eask-file-loaded-hook #'eask--checker-existence)
21572157
(add-hook 'eask-file-loaded-hook #'eask--checker-metadata)
@@ -2230,7 +2230,7 @@ variable we use to test validation."
22302230
(defmacro eask-defcommand (name &rest body)
22312231
"Define an Eask command."
22322232
(declare (doc-string 2) (indent 1))
2233-
(or name (error "Cannot define '%s' as a command" name))
2233+
(or name (error "Cannot define `%s` as a command" name))
22342234
(push name eask-commands)
22352235
(setq eask-commands (delete-dups eask-commands))
22362236
`(defun ,name nil ,@body))

0 commit comments

Comments
 (0)