Spell check all files if dictionary.txt changes

Created on 6 May 2021, over 3 years ago
Updated 12 September 2023, about 1 year ago

Problem/Motivation

It'd be cool if core/scripts/dev/commit-code-check.sh could detect a change in the dictionary and re-run the tests. We can test if the dictionary is in $FILES - also we should only do this on DrupalCI - there's a flag for that too. Also we could extend this to:

running PHPCS on all files if phpcs.xml.dist is updated
running all JS build checks if core/yarn.lock is updated
Thus spoketh @alexpott in #3212547-7: cspell Dictionaries changed, checking all files →

I think it's not only cool, but also necessary to prevent issues like #3212521: [backport] cspell dislikes identifer in core/modules/views/src/Plugin/views/filter/FilterPluginBase.php and will fail any patch touching that file →

Steps to reproduce

Proposed resolution

Detect a change to the dictionary and then run spellcheck:core locally and on drupalci if it is has changed.

  if [[ $FILE == "core/misc/cspell/dictionary.txt" ]]; then
    CSPELL_DICTIONARY_FILE_CHANGED=1;
  fi

Remaining tasks

Review patch #10

User interface changes

API changes

Data model changes

Release notes snippet

📌 Task
Status

Fixed

Version

10.1 ✨

Component
Base  →

Last updated about 24 hours ago

Created by

🇳🇱Netherlands spokje

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

Production build 0.71.5 2024