macOS 10.14 Mojave’s Archive Utility


Majority of macOS users are familiar with the name called Archive Utility. This is the ease-to-use compress tool/app, shipped with macOSs. Although you can’t find it neither in your Application folder nor in your Launchpad. This is located in /System/Library/CoreServices/Applications, along with other critical Apps for macOS. And because of this useful utility App, file compression and expansion became so easy in macOS. Even we don’t need any third party tools to download and install for those purposes. In macOS, any zipped file can be expand by double click into it. Other way, any file can be compressed by secondary click and pick compress option from the menu. And all these are happening because of Archive Utility is running in background

Terminal Commands
  • zip archive.zip file.txt
  • unzip archive.zip
Here we will talk about the Archive Utility in Mojave (latest macOS 10.14+), it’s functionalities and hidden features, which we may ignore or not aware about by mean.

Journey to the Archive Utility

As said earlier, it’s not available in Launchpad, so one can launch it either visiting /System/Library/CoreServices/Applications location or from Spotlight Search.
Once launched, we can check the preferences of Archive Utility (Settings, is the another term for cross platform users).


And here we can find many different settings which can be customise depending on user’s requirements.
For example, we can set expanding settings, which will affect the file retrieving process, when we double clicked the zipped file. Same way archive settings can modify to define how to compress the file.

Lets checkout different options are available inside those dropdown lists.

1. When we double clicked the zipped file, by default, it will expand into the same directory (file path) where the zip was located. If you want to change this default location to your choice, expand the dropdown menu of “Save expanded files” and choose “into…” from there, which allows you to pick any destination from your Mac.
2. You can decide what you would do with zipped file after expansion. For that, reveal the dropdown menu of “After expanding” and pick your choice. By the names of these options, you can easily understand their purposes and effects, after applied.
3. For compressing or archiving, again one can change location from the default setting, which is again the same location where original file is located. Reveal the “Save archive” options.
4. Just like “After expanding” options, one can reveal “After archiving” options to decide the life of original files.
These are the few options I thought one could like to expose to customise their archiving process.

Archiving Options

It’s pretty simple in macOS to archive anything. Pick any file or folder, secondary (right) click on it to reveal options and pick compress from there. And you will be presented a zipped file (.zip).

Every time you will try to compress any file with this method, you will get “.zip”. But you may know, zip is not only file compression format. There are few more like “.cpgz” or “.cpio”, result of UNIX’s GZIP process. As macOS’s foundation is UNIX BSD code, then it should supports those extensions.

So, to reveal archive types, let’s open the Preferences of Archive Utility, just like previous section.
Notice here, under the archiving settings, we have option called, “Use archive format”. Explore the dropdown menu here.
By default, it may says “compressed archive”.

But if you try to compress any file by right click > compress method, you will always get “.zip” file only.
This is a feature of macOS. So, how we can generate other formatted archive file? Answers are with Archive Utility.

1. From Archive Utility menu, go to File > Create Archive… and click.
And you will get CPGZ formatted file.


2. Same way, first choose the archive format as “regular archive”. And then again click on Archive Utility’s File > Create Archive… option, you will get CPIO formatted file.

3. One can try with “Zip archive” from here and same way will get ZIP formatted file this time.

If one tries to achieve all these three archiving methods, can achieves the screen like below.


If you compare the compressed file sizes of all these methods, ZIP and CPGZ are the actual file compression processes, where CPIO file having same size like the original file.

Troubleshooting

While supporting your customers, you may face following questions.

1. From my Desktop, trying to compress file by “right click > compress”, but unable to see the zipped file in Desktop?

Solution: Ask them to open Finder window and search in Recents section from left navigation bar. If Archive Utility is working, then they found the zipped file there. So may be the zipped file destination is something else. Now you know from where you have to look for changes.

Open Archive Utility > Preferences > Save archive > Change on client’s choice

2. From my Desktop, trying to expand zipped file by double click, but unable to see the files in Desktop?

Solution: Suggest the way mentioned in 1st question. And then if client wants, change the “Save expanded files” destination.

Open Archive Utility > Preferences > Save expanded files > Change on client’s choice

3. Getting error while expanding an archive as well as creating an archive?

Solution: May be the Archive Utility got corrupted. After basic troubleshooting like checking file permissions, parental controls, terminal zip command (mentioned earlier) etc., if still not working, then try to reload the preferences services from Activity Monitor.

Open Activity Monitor from Launchpad or Spotlight Search.
Search for “cfprefsd” services. These services run all preferences for your macOS. You may not terminate these services, permanently, as they are vital for your OS’s smooth run, but can relaunch to refresh all preferences.
For that, from the list in Activity Monitor, select “cfprefsd” process and click on cross symbol from top bar of the window. A dialog box appear to ask for Quit or Force Quit. In this case go with Force Quit option. You may Force Quit all the “cfprefsd” services. Wait for few moments, and the services automatically relaunch. This way preferences related problems get solved.
If the problem if still persisting, in that case you have to replace the Archive Utility app with same app from another Mac where the Archive Utility is perfectly working.

Conclusion 

Archive Utility is blessing on macOS user’s, who plays with zip and unzip in regular basis, without bothering about any third party installations. Please share any other troubleshooting related queries here, so that we can talk about those and come with proper solutions to make our client happier.

#apple #macos #mojave #compress #zip #archive #troubleshoot

Comments

Popular posts from this blog

Swift Programming: Big O notation for complexity checking