Ok, so the quick way to find given directory is just to use SystemOpen @ dir
. E.g.
SystemOpen @ $UserBaseDirectory
I go there all the time so I added a menu to the main menu in order to not write this each time. Here's the procedure:
(*aux function*)
dir = FileNameJoin[{ #, "SystemFiles", "FrontEnd", "TextResources",
$OperatingSystem /. "MacOSX" -> "Macintosh"}] &;
(*we are going to play inside $UserBaseDirectory to not break installation*)
(*not everything from $ID is present in $USB so let's create that directory and file if that's necessary*)
If[Not @ DirectoryQ @ #,
CreateDirectory[#, CreateIntermediateDirectories -> True]
] & @ dir @ $UserBaseDirectory;
CopyFile[
FileNameJoin[{dir@$InstallationDirectory, "MenuSetup.tr"}],
FileNameJoin[{dir@$UserBaseDirectory, "MenuSetup.tr"}]
];
SystemOpen @ FileNameJoin[{dir@$UserBaseDirectory, "MenuSetup.tr"}]
Now you have to add the menu anywhere you find it handy:
Menu["Locations",
{
MenuItem["$UserBaseDirectory", KernelExecute[
SystemOpen[ $UserBaseDirectory] ], MenuEvaluator -> "System" ],
MenuItem["$InstallationDirectory", KernelExecute[
SystemOpen[ $InstallationDirectory] ], MenuEvaluator -> "System" ],
MenuItem["$TemporaryDirectory", KernelExecute[
SystemOpen[ $TemporaryDirectory] ], MenuEvaluator -> "System" ],
MenuItem["NotebookDirectory[]", KernelExecute[
If[
ReplaceAll["FileName", NotebookInformation[SelectedNotebook[]]] =!= "FileName",
SystemOpen[ NotebookDirectory[ SelectedNotebook[] ] ]
]],
MenuEvaluator -> "System"
]
}],
Don't miss any comma etc. Save, restart MMA and be happy:
SystemOpen @ $UserBaseDirectory
? $\endgroup$defaults write com.apple.finder AppleShowAllFiles YES
and then relaunch the Finder. You can also use Mathematica'sSystemOpen
command to access them, as @Kuba suggested. $\endgroup$$UserBaseDirectory
and$BaseDirectory
OS X. Did you do some kind of custom install? For instance,$BaseDirectory
is usually/Library/Mathematica
and this directory is not hidden in Yosemite. (I have not upgraded to El Capitan. $\endgroup$SystemOpen[$BaseDirectory]
returns$Failed
: i'm using Mathematica 12.0 and macOS 10.15.4 $\endgroup$