Skip to content

plugin-scanner-check

Runs the community directory’s scanner checks on the developer’s machine, by running obsidianmd/obsidian-workflows itself: the GitHub Action the directory team points to as matching its scanner, which carries the scanner’s own ESLint and Stylelint rulesets. Running the action, rather than a copy of its rules, is what keeps the local answer the scanner’s answer when the rulesets change: only OBSIDIAN_WORKFLOWS_VERSION moves.

The action’s bundled dist/index.js is downloaded once per version into node_modules/.cache and run with Node, in its pr mode with the scanner lint and strict on and the build off, under the environment variables an Actions runner would set. It installs the scanner’s ESLint and Stylelint into a temporary folder on every run, which takes minutes. Its ::error / ::warning / ::notice workflow commands are turned back into plain lines.

Interface Description
RunScannerCheckOptions Parameters for runScannerCheck.
ScannerCheckResult The result of runScannerCheck.
Function Description
formatWorkflowCommandOutput Turns the workflow commands in a GitHub Action’s output into plain lines: an annotation becomes <level>: <file>:<line> <message>, a group start its title, and the other commands are dropped.
runScannerCheck Runs the scanner checks of obsidianmd/obsidian-workflows on the plugin. See the @file overview.
Variable Description
OBSIDIAN_WORKFLOWS_VERSION The obsidianmd/obsidian-workflows release whose scanner rulesets are run.