mdsmith
Esc
    v0.52.0 GitHub
    MDS066 code ready

    MDS066: commands-show-output

    A fenced code block whose every non-blank line begins with $ and shows no output must drop the prompt.

    # Config

    Enable (default):

    rules:
      commands-show-output: true

    Disable:

    rules:
      commands-show-output: false

    # Autofix

    mdsmith fix strips the leading $ from every non-blank content line of the offending block. Blank lines pass through unchanged. Only fenced code blocks are inspected; indented blocks are out of scope.

    # Examples

    # Good — block shows output

    # Title
    
    A block that shows both commands and their output is fine:
    
    ```sh
    $ ls
    foo bar
    $ pwd
    /home/user
    ```

    # Good — no $ prompts

    # Title
    
    A block that has no `$ ` prefixes is fine:
    
    ```sh
    ls
    pwd
    ```

    # Bad — only commands, no output

    # Title
    
    Commands shown with `$` and no output:
    
    ```sh
    $ ls
    $ pwd
    ```

    # Meta-Information

    • ID: MDS066
    • Name: commands-show-output
    • Status: ready
    • Default: enabled
    • Fixable: yes
    • Implementation: source
    • Category: code
    • markdownlint: MD014 (commands-show-output)
    • rumdl: MD014 (commands-show-output)
    • mado: MD014 (commands-show-output)