Skip to content

Support vim encoding coding hints #3956

@clach04

Description

@clach04

I have a few files (for testing purposes) that explicitly list the encoding (so that view/editing works sanely), and one of them happens to be cp1252.

Which means codespell check results in output like:

WARNING: Cannot decode file using encoding "utf-8": .\README.md
WARNING: Trying next encoding "iso-8859-1"

It also means that correctly declared iso-8859-1 files get treated as utf-8 on the first attempt to determine encoding.

It would be really neat if coding could be supported :-) E.g. handle files like:

... possible lines at head... possibly not....
# -*- coding: cp-1252 -*-
....

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions