Skip to content

FR: Allow overwriting file classification heuristic #127

@phst

Description

@phst

Gazelle uses a heuristic to classify source files (

func getFileInfo(
). This works fine most of the time, but sometimes fails. For example, Windows binaries will often define wmain or _tmain instead of main. Therefore it would be nice to allow source authors to override the classification. For example, the source code parser could look for directives in comments of the form

// gazelle:source_kind binary

to force generation of a cc_binary rule.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions