Line

From wikieduonline
Revision as of 09:52, 19 April 2023 by Welcome (talk | contribs)
Jump to navigation Jump to search
This article is a Draft. Help us to complete it.

wikipedia:line

Count lines:

Concatenate lines:

New line:

Merge every two lines:

  • cat /path/tofile.txt | paste -d " " - -[1]
  • cat /path/tofile.txt | xargs -n2 -d'\n'

Add line:

grep -qxF 'your text "additional text"' yourfile.txt || echo 'your text "additional text"' >> yourfile.txt

Activities

Related

See also

  • https://stackoverflow.com/a/9605450
  • Advertising: