1
0
Fork 0
mirror of https://github.com/tldr-pages/tldr.git synced 2024-11-02 06:57:55 +01:00
tldr/pages/common/diff.md
2015-10-23 08:02:34 +08:00

23 lines
424 B
Markdown

# diff
> Compare files and directories
- Compare files
`diff {{file1}} {{file2}}`
- Compare files, ignoring white spaces
`diff -w {{file1}} {{file2}}`
- Compare files, showing differences side by side
`diff -y {{file1}} {{file2}}`
- Compare directories recursively
`diff -r {{directory1}} {{directory2}}`
- Compare directories, only showing the names of files that differ
`diff -rq {{directory1}} {{directory2}}`