Mac App Compare Folder Contents

Let's say you've copied an older version of a folder off of your backup drive, and you need to find out how its contents compare to the current version on your Mac. A lot of folks don't know that there's a built-in way to do that, and it's pretty easy to use and understand. It's accessed through the Terminal, so first you'll open that program from your Applications> Utilities folder.

The MacOS folder will contain a single file, the Resources folder will contain files and additional folders. How do I know if the Application is an Application Bundle? After selecting an application's icon in the Application folder and either useng the Action Button in the Finder toolbar, a control-click, or right-click on the icon and if you.

When you've got it ready to go, type diff in at the prompt followed by a space, and then drag the two folders you want to compare and drop them on the Terminal window. It doesn't matter what order you do this in, and you don't have to type a space in between, either.

That'll make Terminal fill in the paths to those folders for you, and you should see something like this:

Press Return to implement the command, and your Terminal window will fill with delicious data.

Holy crap, that's a lot of gobbledygook. The thing is, though, that the gobbledygook is pretty interesting. From it, I can tell that I've got two JPEG files with the same name but different content:

I see that one file only lives in the copy and is missing from the original folder:

And I also find that a text file has different content than its counterpart:

(I typed 'text differs' within one of them to show you how it'd look.)

So that's all pretty handy, but you have a few options you can add on, too, to make things even better. For example, you can use the '-r' option to force the command to search all subfolders, like so:

Another often-used choice is '-q,' which'll output less-detailed text that only tells you whether files differ and not how they differ. This makes your results much easier to read! Of course, you can combine this with the '-r' option, too.

  1. Oct 18, 2019  The Finder is the first thing that you see when your Mac finishes starting up. It opens automatically and stays open as you use other apps. It includes the Finder menu bar at the top of the screen and the desktop below that. It uses windows and icons to show you the contents of your Mac, iCloud Drive, and other storage devices. It's called the.
  2. Feb 06, 2018  The diff command is available by default on the Mac, and it works the same in Linux and other unix operating systems as well, just in care you were wondering, and for Windows users it’s quite similar to how the ‘fc’ file compare tool works. For best results you’ll want to be working with plain text files of some sort and not rich text.

Additionally, you can use diff to compare files instead of folders by dragging a couple of those onto Terminal instead:

That tells me which lines are different and how.

Finally, just as with a lot of Terminal commands, you can send the results to a file instead of just into a Terminal window. This is often much easier to read and work with, but it does require you to be a bit familiar with things like paths. For this, you'll use the pipe ('>') command, like so:

I know that looks complicated, but the English translation of it is 'compare the two folders I've listed here, and send the results to a file on my Desktop called comparison.txt.' Note that if you use one pipe ('>'), as I've done above, that tells Terminal to overwrite a file that exists with that name, if any; if you use two pipes ('>>'), it asks Terminal to add to any existing files. So you could compare many different folders and pipe the results out to the same file, using the double-pipe every time to force it to add to your text rather than replacing it.

Neat, right? Not scary at all, is it? OK, Terminal's a little scary for some folks. I figure that certain people get reminded of playing text-based adventures like Zork way back when; you won't get eaten by a grue, I promise.

The Finder is the first thing that you see when your Mac finishes starting up. It opens automatically and stays open as you use other apps. It includes the Finder menu bar at the top of the screen and the desktop below that. It uses windows and icons to show you the contents of your Mac, iCloud Drive, and other storage devices. It's called the Finder because it helps you to find and organize your files.

Open windows and files

To open a window and see the files on your Mac, switch to the Finder by clicking the Finder icon (pictured above) in the Dock. Switching to the Finder also reveals any Finder windows that might be hidden behind the windows of other apps. You can drag to resize windows and use the buttons to close , minimize , or maximize windows. Learn more about managing windows.

When you see a document, app, or other file that you want to open, just double-click it.

List Folder Contents

Contents

Change how your files are displayed

To change how files are displayed in Finder windows, use the View menu in the menu bar, or the row of buttons at the top of the Finder window. You can view files as icons , in a list , in columns , or in a gallery . And for each view, the View menu provides options to change how items are sorted and arranged, such as by kind, date, or size. Learn more about customizing views.

When you view files in a gallery, you can browse your files visually using large previews, so it's easy to identify images, videos, and all kinds of documents. Gallery View in macOS Mojave even lets you play videos and scroll through multipage documents. Earlier versions of macOS have a similar but less powerful gallery view called Cover Flow .

Windows Compare Contents Of Folders


Gallery View in macOS Mojave, showing the sidebar on the left and the Preview pane on the right.

Use the Preview pane

The Preview pane is available in all views by choosing View > Show Preview from the menu bar. Or press Shift-Command (⌘)-P to quickly show or hide the Preview pane.

macOS Mojave enhances the Preview pane in several ways:

  • More information, including detailed metadata, can be shown for each file. This is particularly useful when working with photos and media, because key EXIF data, like camera model and aperture value, are easy to locate. Choose View > Preview Options to control what information the Preview pane can show for the kind of file selected.
  • Quick Actions let you easily manage or edit the selected file.

Use Quick Actions in the Preview pane

With Quick Actions in macOS Mojave, you can take actions on a file without opening an app. Quick Actions appear at the bottom of the Preview pane and vary depending on the kind of file selected.

  • Rotate an image
  • Mark up an image or PDF
  • Combine images and PDFs into a single PDF file
  • Trim audio and video files

To manage Quick Actions, click More , then choose Customize. macOS Mojave includes a standard set of Quick Actions, but Quick Actions installed by third-party apps also appear here. You can even create your own Quick Actions using Automator.

Use Stacks on your desktop

macOS Mojave introduces Stacks, which lets you automatically organize your desktop into neat stacks of files, so it's easy to keep your desktop tidy and find exactly what you're looking for. Learn more about Stacks.

The sidebar in Finder windows contains shortcuts to AirDrop, commonly used folders, iCloud Drive, devices such your hard drives, and more. Like items in the Dock, items in the sidebar open with just one click.

To change the items in your sidebar, choose Finder > Preferences from the Finder menu bar, then click Sidebar at the top of the preferences window. You can also drag files into or out of the sidebar. Learn more about customizing the sidebar.

Search for files

To search with Spotlight, click the magnifying glass in the menu bar, or press Command–Space bar. Spotlight is similar to Quick Search on iPhone or iPad. Learn more about Spotlight.

To search from a Finder window, use the search field in the corner of the window:


When you select a search result, its location appears at the bottom of the window. To get to this view from Spotlight, choose “Show all in Finder” from the bottom of the Spotlight search results.

In both Spotlight and Finder, you can use advanced searches to narrow your search results.

Delete files

To move a file to the Trash, drag the file to the Trash in the Dock. Or select one or more files and choose File > Move To Trash (Command-Delete).

To remove a file from the Trash, click the Trash to open it, then drag the file out of the Trash. Or select the file and choose File > Put Back.

To delete the files in the Trash, choose File > Empty Trash. The storage space used by those files then becomes available for other files. In macOS Sierra, you can set up your Mac to empty the trash automatically.