Hongmu Notes

paste

合并文件�

100% Browser local processing 0 Data upload

Common examples

Combine all lines into one, using tab as separator

paste {{[-s|--serial]}} {{路径/到/文件}}

Combine all lines into one using specified delimiter

paste {{[-s|--serial]}} {{[-d|--delimiters]}} {{分隔符}} {{路径/到/文件}}

Merge two files side by side, each tab separated into separate columns

paste {{路径/到/文件1}} {{路径/到/文件2}}

Merge two files side by side, each separated into separate columns with a specified delimiter

paste {{[-d|--delimiters]}} {{分隔符}} {{路径/到/文件1}} {{路径/到/文件2}}

Merge all lines in the two files alternately

paste {{[-d|--delimiters]}} '\n' {{路径/到/文件1}} {{路径/到/文件2}}

Tip: curly braces{{…}}It is the parameter that needs to be replaced (path, file name, etc.); the command is only executed in the local terminal, and this site does not save any input.

English original text comparison

Expand English instructions and examples (source tldr-pages)

Merge lines of files. More information

Join all the lines into a single line, using `TAB` as delimiter

paste {{[-s|--serial]}} {{path/to/file}}

Join all the lines into a single line, using the specified delimiter

paste {{[-s|--serial]}} {{[-d|--delimiters]}} {{delimiter}} {{path/to/file}}

Merge two files side by side, each in its column, using `TAB` as delimiter

paste {{path/to/file1}} {{path/to/file2}}

Merge two files side by side, each in its column, using the specified delimiter

paste {{[-d|--delimiters]}} {{delimiter}} {{path/to/file1}} {{path/to/file2}}

Merge two files, with lines added alternatively

paste {{[-d|--delimiters]}} '\n' {{path/to/file1}} {{path/to/file2}}

command information

command namepaste
Purpose合并文件�
Applicable platforms通用
Number of examples5 Article
Official documentationhttps://www.gnu.org/software/coreutils/manual/html_node/paste-invocation.html
Data sourcetldr-pages(CC-BY-4.0)· Community Chinese Translation

FAQ

paste What does the command do?

合并文件�

paste How to use it?

Pages listed by scene5Commonly used examples: Each example first explains the purpose, and then gives a complete command that can be directly copied (the parameters that need to be replaced are in the curly brackets).

paste What are the most commonly used operations?

Combine all lines into one, using tab as separator:paste {{[-s|--serial]}} {{路径/到/文件}}

What do the curly braces in the command mean?

curly braces{{…}}Indicates that you need to replace it with your own value, such as path and file name; square brackets for parameters with the same name (such as[-C|--directory]) indicates optional writing.