Glossary

paste

paste is the complement of cut: instead of splitting columns out of a file, it joins lines from several files with a separator. By default the separator is a tab.

paste names.txt phones.txt              # tab-separated columns
paste -d, names.txt phones.txt          # comma-separated (make CSV)
paste -s names.txt                      # turn lines into one tab-separated row
paste -d: /etc/passwd                   # no-op: already colon-separated

paste is the quickest way to stitch together parallel data: for example, merging two sorted lists into a two-column TSV for further processing.

Related terms: cut, join

Discussed in:

This site is currently in Beta. Contact: Chris Paton

Textbook of AI · Textbook of Usability · Textbook of Digital Health

Auckland Maths and Science Tutoring

AI tools used: Claude (research, coding, text), ChatGPT (diagrams, images), Grammarly (editing).