Skip to content

Support stdin as old file #20

Description

@cweiske

I'd like to diff the changes that were done to my git-tracked yarn.lock file before committing.
For that it'd be nice if I would not have to store the old version in a file, but to be able to pipe it into yarn-lock-diff:

git show HEAD:yarn.lock | yarn-lock-diff --new typo3/packages/giby/yarn.lock --old -

Currently I get an error Error: File does not exist "-" for that.
Passing - as file name means that stdin should be used (see "The Open Group Base Specifications Issue 7" https://pubs.opengroup.org/onlinepubs/9699919799/basedefs/V1_chap12.html "Guideline 13")

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