Skip to main content
added 17 characters in body
Source Link
sed 's/\(.*\)/-o \1:1/' file.txt | xargs /path/to/command

The sed substitution reads as: replace the text in a given line with "-o the_original_text:1". Then the xargs command takes those modified lines of text and concatenates them as appropriate for command line arguments

sed 's/\(.*\)/-o \1:1/' file.txt | xargs

The sed substitution reads as: replace the text in a given line with "-o the_original_text:1". Then the xargs command takes those modified lines of text and concatenates them as appropriate for command line arguments

sed 's/\(.*\)/-o \1:1/' file.txt | xargs /path/to/command

The sed substitution reads as: replace the text in a given line with "-o the_original_text:1". Then the xargs command takes those modified lines of text and concatenates them as appropriate for command line arguments

replaced locale dependent quotes with single (\047) and double (\042) quotes; formatting
Source Link
RudiC
  • 9k
  • 2
  • 12
  • 22
sed ‘s's/\(.*\)/-o \1:1/' file.txt | xargs

The sedsed substitution reads as: replace the text in a given line with "-o the_original_text:1”1". Then the xargsxargs command takes those modified lines of text and concatenates them as appropriate for command line arguments

sed ‘s/\(.*\)/-o \1:1/ file.txt | xargs

The sed substitution reads as: replace the text in a given line with -o the_original_text:1”. Then the xargs command takes those modified lines of text and concatenates them as appropriate for command line arguments

sed 's/\(.*\)/-o \1:1/' file.txt | xargs

The sed substitution reads as: replace the text in a given line with "-o the_original_text:1". Then the xargs command takes those modified lines of text and concatenates them as appropriate for command line arguments

Source Link

sed ‘s/\(.*\)/-o \1:1/‘ file.txt | xargs

The sed substitution reads as: replace the text in a given line with “-o the_original_text:1”. Then the xargs command takes those modified lines of text and concatenates them as appropriate for command line arguments