User Controls

what is standard input redirect linux <

  1. #1
    kush_blunt Houston
    what is the standard input redirect operator < doing/good for? I have literally been thinking about this for days this week. like... i see about the wc command, but other than this isn't it redundant/vestigial?

    please help, i want to learn and do a good job.. google has not been friendly
  2. #2
    Lanny Bird of Courage
    I've never actually used it to do something useful, like there are plenty of use cases for redirecting input to stdin but I always cat a file and pipe it to the next process and that way you don't have to puzzle over the operator precedence. I imagine it's mostly there for symmetry with output redirection. There may also be an argument for keeping what's core functionality of "read file to command's stdin" in the shell codebase rather than a util codebase.
    The following users say it would be alright if the author of this post didn't die in a fire!
  3. #3
    aldra JIDF Controlled Opposition
    yeah, I've never actually needed it. there are probably niche cases but I've always been able to use pipe/tee in its place
  4. #4
    kush_blunt Houston
    I almost feel like it's a cruel joke
Jump to Top