Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

False positive: hdahad #998

Open
kdeldycke opened this issue Apr 16, 2024 · 1 comment
Open

False positive: hdahad #998

kdeldycke opened this issue Apr 16, 2024 · 1 comment

Comments

@kdeldycke
Copy link

My markdown document containing CLI with references to hda (i.e. the master device on the first ATA channel), is auto-corrected to had:

$ typos content/2005/qemu-commands.md

error: `hda` should be `had`
  --> content/2005/qemu-commands.md:19:29
   |
19 |   $ qemu -cdrom /dev/cdrom -hda /home/kevin/qemu-disk-image.qcow -boot d
   |                             ^^^
   |

error: `hda` should be `had`
  --> content/2005/qemu-commands.md:25:41
   |
25 |   $ qemu -cdrom /home/kevin/ubuntu.iso -hda /home/kevin/qemu-disk-image.qcow -boot d
   |                                         ^^^
   |

Produced with latest typos:

$ typos --version
typos-cli 1.20.8
@kdeldycke
Copy link
Author

In the mean time, I am ignoring these false positive with the following config in my pyproject.toml:

[tool.typos]
default.extend-ignore-re = [
    # error: `hda` should be `had`
    #   --> content/2005/qemu-commands.md:19:29
    #    |
    # 19 |   $ qemu -cdrom /dev/cdrom -hda /home/kevin/qemu-disk-image.qcow -boot d
    #    |                             ^^^
    #    |
    " -hda ",
    # error: `hda` should be `had`
    #   --> ./content/2006/hardware-commands.md:25:28
    #    |
    # 25 | - Low-level format of the `hda` device:
    #    |                            ^^^
    #    |
    "`hda`",
]

I'm OK to have this issue closed as an extreme edge-case as I'm pretty sure I'm the only one out there nitpicking on that! 😅

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant