![Azure data studio connect to mysql](https://loka.nahovitsyn.com/93.jpg)
Lines that begin with refer to the second file, alpha2. This is the first difference between the two files that diff found. The 4c4 in our example tell us that line four of alpha1 must be changed to match line four of alpha2.
![compare folders with terminal compare folders with terminal](https://www.novell.com/de-de/documentation/opensuse111/opensuse111_kdeuser/graphics/kde_dolphin_splitview.png)
Both files contain the phonetic alphabet but the second file, alpha2, has had some further editing so that the two files are not identical. The order of the files on the command line determines which file diff considers to be the ‘first file’ and which it considers to be the “second file.” In the example below alpha1 is the first file, and alpha2 is the second file. Let’s dive right in and analyze two files. In this tutorial, we’re going to look at the most useful human-friendly ways to use diff.
Compare folders with terminal Patch#
The diff command was designed to find differences between source code files and to produce an output that could be read and acted upon by other programs, such as the patch command.
![compare folders with terminal compare folders with terminal](https://www.macobserver.com/imgs/tips/20131018_Output.jpg)
If you keep that in mind you’ll find it easier to understand the output from diff. The diff command compares two files and produces a list of the differences between the two. To be more accurate, it produces a list of the changes that would need to be made to the first file, to make it match the second file.
![Azure data studio connect to mysql](https://loka.nahovitsyn.com/93.jpg)