0

To mount my RAM drive I am using:

    diskutil erasevolume HFS+ 'RAM_Disk' `hdiutil attach -nomount ram://51200`

To hide it I'm using:

   chflags hidden /Volumes/RAM_Disk'

However the ram drive still appears in Finder's sidebar.

I do not want all the 'hard drives' not to be listed under devices in Finder's sidebar, just this particular RAM drive. Manually one can just drag it off the sidebar but I need to do this programmatically preferably with Shell Bash and if not that then with applescript.

I have tried changing the com.apple.sidebarlists.plist but this doesn't help.

I need this to work also in El Capitan.

Cœur
  • 37,241
  • 25
  • 195
  • 267
Trevor
  • 525
  • 2
  • 6
  • 19
  • This may help... http://stackoverflow.com/a/16769092/2836621 – Mark Setchell Jan 28 '16 at 08:48
  • Thanks for the link. I don't know how I could implement that API into my NodeJS project but think that it wouldn't work on El Captain as it looks like it makes the changes to the com.apple.sidebarlists.plist that I manually applied with out success. I could me that I could change the visibility setting for the item entry. I shall try that out and post the result. P.s. I did restart Finder. – Trevor Jan 28 '16 at 12:34

0 Answers0