Skip to content
This repository has been archived by the owner on Mar 3, 2023. It is now read-only.

cli: Open stdin as a file when present #11184

Closed
wants to merge 1 commit into from
Closed

Commits on Mar 17, 2016

  1. cli: Open stdin as a file when present

    The [atom cli discards its input stdin][1]
    when other editors would open a new document containing that text.
    
    This change writes input from stdin to a new temporary file
    and inserts that file as the first argument to the atom executable.
    It only does that when stdin is not at tty,
    i.e. running `git diff | atom` creates and opens a temporary file
    but running `atom some/file` does not.
    
    [1]: https://discuss.atom.io/t/it-would-be-nice-to-be-able-to-pipe-standard-out-to-atom-and-have-it-open-in-an-unsaved-document/4781
    mkhl committed Mar 17, 2016
    Configuration menu
    Copy the full SHA
    c02d051 View commit details
    Browse the repository at this point in the history