Skip to content

[FEATURE] Add support for --staged flag to lint only staged files #50

@PrasannaMishra001

Description

@PrasannaMishra001

Current Behavior

omegaup-hook-tools does not currently support a --staged flag to restrict linting to only staged files. As a result, callers such as stuff/lint.sh in the main omegaup repository cannot delegate staged-only linting and must lint all files.

Expected Behavior

Add support for a --staged flag that uses git diff --cached --name-only internally to determine the file list. This will allow tools like ./stuff/lint.sh --staged to lint only staged files, improving pre-commit performance and developer workflow.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions