1
0
Fork 0
mirror of https://github.com/tldr-pages/tldr.git synced 2025-04-23 18:02:08 +02:00
tldr/pages/windows/comp.md
Emily Grace Seville c52cc074d9
windows/*.md: make placeholders more compatible with CLIP ones (#9872)
* Make placeholders more compatible with CLIP ones

* Update pages/windows/doskey.md

Co-authored-by: Jack Lin <blueskyson1401@gmail.com>

* Update pages/windows/doskey.md

Co-authored-by: Jack Lin <blueskyson1401@gmail.com>

---------

Co-authored-by: Jack Lin <blueskyson1401@gmail.com>
2023-02-20 15:23:49 +08:00

37 lines
864 B
Markdown

# comp
> Compare the contents of two files or sets of files.
> Use wildcards (*) to compare sets of files.
> More information: <https://learn.microsoft.com/windows-server/administration/windows-commands/comp>.
- Compare files interactively:
`comp`
- Compare two specified files:
`comp {{path\to\file1}} {{path\to\file2}}`
- Compare two sets of files:
`comp {{path\to\directory1}}\* {{path\to\directory2}}\*`
- Display differences in decimal format:
`comp /d {{path\to\file1}} {{path\to\file2}}`
- Display differences in ASCII format:
`comp /a {{path\to\file1}} {{path\to\file2}}`
- Display line numbers for differences:
`comp /l {{path\to\file1}} {{path\to\file2}}`
- Compare files case-insensitively:
`comp /c {{path\to\file1}} {{path\to\file2}}`
- Compare only the first 5 lines of each file:
`comp /n={{5}} {{path\to\file1}} {{path\to\file2}}`