タグ

関連タグで絞り込む (1)

タグの絞り込みを解除

shell_scriptに関するdynamicsoarのブックマーク (1)

  • How to use > in an xargs command?

    I want to find a bash command that will let me grep every file in a directory and write the output of that grep to a separate file. My guess would have been to do something like this ls -1 | xargs -I{} "grep ABC '{}' > '{}'.out" but, as far as I know, xargs doesn't like the double-quotes. If I remove the double-quotes, however, then the command redirects the output of the entire command to a singl

    How to use > in an xargs command?
    dynamicsoar
    dynamicsoar 2018/11/12
    まさに完全に求めていたものだ。さらに「-0 option なしで xargs 使うな」「lsを使うな、findを使え」とか知らなかったことが色々…ためになる。
  • 1