📜 ⬆️ ⬇️

Get rid of subfolders in Applications

As you know, on a Mac application are a package (folder with the extension .app), which contains all the necessary resources and an executable file. In most cases, such a package is self-sufficient and, when moved to an arbitrary location, the application will start and run. However, some applications are not just .app, but a folder in which besides it are other necessary files for the application. Ported applications are more likely to do this, but there are some native Macs located in subfolders (a stone in the direction of iWork and Microsoft Office).
This non-standard structure creates two small inconveniences:
  1. to run the application requires 1 click more
  2. the folder does not have an application icon, making it harder to find visually
Ideally, all applications should be accessible with one click, and at least the subfolders in the Applications folder should not be visible.

Conventionally, all such applications can be divided into two categories: those that can be safely moved while maintaining the folder structure, and those that are not worth it. I got Quake 3, AC3D, Squeak, Master Key and Stepmania in the first category, and MacPorts, TeX, Adobe, iWork and Microsoft Office in the second category.

To implement our insidious plans, we use pseudonyms (similar to shortcuts in windows, symbolic links are not available here because the application will consider itself running from Applications where there are no required files) and the SetFile utility from Developer Tools.
  1. Create a folder / Applications / Hidden and place in it all the folders with applications that can be moved.
  2. For each application package (.app), create an alias (right click -> create alias), rename it and put it in / Applications.
  3. For each unmovable application we will also create by pseudonym and put in / Applications.
  4. In the terminal:
    cd /Applications
    sudo SetFile -a V Hidden #
    sudo SetFile -a V < > # ,

  5. Sometimes you need to restart the dock so that the necessary folders disappear.
  6. Enjoy!
After that, all your applications are available in one click and with beautiful icons:

')
PS To access the Hidden folder, open the Finder, press Shift + Command + G and type / Applications / Hidden.
To make the hidden folder visible again, enter in the terminal:
sudo SetFile -av < >

Pps . I know that it is faster to run applications through spotlight, but through Applications in the dock I like it more.

Source: https://habr.com/ru/post/99619/


All Articles