refactor(cli): make all searches case-sensitive
This is more predictable, and is safe as a global default in CLI sessions (but not in interactive ones). This indirectly fixes case insensitivity in our commit linter rules.
This commit is contained in:
parent
a3f917c42d
commit
abc16ef68c
3 changed files with 6 additions and 6 deletions
|
@ -197,8 +197,7 @@ one wants that.")
|
||||||
|
|
||||||
(defun doom-autoloads--scan (files &optional exclude literal)
|
(defun doom-autoloads--scan (files &optional exclude literal)
|
||||||
(require 'autoload)
|
(require 'autoload)
|
||||||
(let (case-fold-search ; case-sensitive regexp from here on
|
(let (autoloads)
|
||||||
autoloads)
|
|
||||||
(dolist (file files (nreverse (delq nil autoloads)))
|
(dolist (file files (nreverse (delq nil autoloads)))
|
||||||
(when (and (or (null exclude)
|
(when (and (or (null exclude)
|
||||||
(seq-remove (doom-rpartial #'string-match-p file)
|
(seq-remove (doom-rpartial #'string-match-p file)
|
||||||
|
|
|
@ -182,8 +182,7 @@
|
||||||
|
|
||||||
(defun doom-cli--ci-lint-commits (from &optional to)
|
(defun doom-cli--ci-lint-commits (from &optional to)
|
||||||
(let ((errors? 0)
|
(let ((errors? 0)
|
||||||
commits
|
commits)
|
||||||
case-fold-search)
|
|
||||||
(with-temp-buffer
|
(with-temp-buffer
|
||||||
(insert
|
(insert
|
||||||
(cdr (doom-call-process
|
(cdr (doom-call-process
|
||||||
|
@ -201,8 +200,8 @@
|
||||||
(point-max))))))
|
(point-max))))))
|
||||||
commits)))
|
commits)))
|
||||||
(dolist (commit commits)
|
(dolist (commit commits)
|
||||||
(let (errors)
|
(with-temp-buffer
|
||||||
(with-temp-buffer
|
(let (errors)
|
||||||
(save-excursion (insert (cdr commit)))
|
(save-excursion (insert (cdr commit)))
|
||||||
(dolist (rule doom-cli-commit-rules)
|
(dolist (rule doom-cli-commit-rules)
|
||||||
(save-excursion
|
(save-excursion
|
||||||
|
|
|
@ -69,6 +69,8 @@ purpose.")
|
||||||
(setq make-backup-files nil)
|
(setq make-backup-files nil)
|
||||||
;; Stop user configuration from interfering with package management
|
;; Stop user configuration from interfering with package management
|
||||||
(setq enable-dir-local-variables nil)
|
(setq enable-dir-local-variables nil)
|
||||||
|
;; Reduce ambiguity, embrace specificity. It's more predictable.
|
||||||
|
(setq-default case-fold-search nil)
|
||||||
|
|
||||||
;; Default to using all cores, rather than half of them, since we compile things
|
;; Default to using all cores, rather than half of them, since we compile things
|
||||||
;; ahead-of-time in a non-interactive session.
|
;; ahead-of-time in a non-interactive session.
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue