Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

akaPeach

macrumors newbie
Original poster
Jul 12, 2011
16
0
Okay so I'm a little bit confused here. I've got a folder that I'm trying to hide (unused folder for a plugin but creates itself if I delete it, I do this with all these types of folders) but when I use the
Code:
chflags hidden
command in terminal, it says I don't have permission. But in the sharing and and permissions part of the Get Info window, I clearly do.. I have a feeling that it has something to do with the greyed out "Locked" checkbox.

Anyone care to help?
 

Attachments

  • Screen Shot 2016-11-03 at 9.09.36 pm.png
    Screen Shot 2016-11-03 at 9.09.36 pm.png
    100.8 KB · Views: 999
What is the output of
Code:
ls -leO ~/Documents

with respect to this file (as well as the line(s) below it)?
 
Sigh….

Here I am - writing from the 'future'.

Hopefully, you've resolved this ..thing, and hopefully, you stay away from Terminal - unless you know what you're doing.

Your 'problem's written very vaguely.

Let me see if I get what you're writing; for some reason, you're trying to 'hide' a folder', and - for some reason (?!?!) you're doing this through Terminal (have I got it, so far?)

Let me ask; why do you need to 'hide' this folder? So others - who've access to your 'outer don't see it/screw with it?

That's the only reason I can think of 'hiding' (you mean making 'invisible', correct?)

Ok - let's stay simple (yeah, I do know Terminal, very well, but, the best answer's always the simplest - learn that rule, and try to stick with, ok;)).

Highlight the folder, and hit 'get info' (⌘>'I'). You'll see a little 'lock' icon, on the bottom-right, and because you say you're not able to do…what you want with it, I'm guessing it's 'locked'. Click on it. It'll bring up a dialogue - asking for administrator/your password. Enter the password. The icon should now be an 'open lock'.

Now - if you want to use Terminal, do this;

  • Launch the Terminal, found in /Applications/Utilities/ or from Launchpad
  • Type the following command:
    chflags hidden /path/to/folder/
  • When finished, close out of Terminal
As an example, to hide a folder in the home directory named “Top Secret” the command would be:
chflags hidden ~/Top Secret/

Now that the folder is hidden, here is how to access it:
  • From the Mac OS X desktop, hit Command>Shift>G to bring up the “Go To Folder” window
  • Enter the same path to the folder as you used when hiding it:
Now you'll be inside the hidden folder, able to open, copy, move, and use the contained files and folders as usual.

To un-hide:
If you no longer want the folder to be hidden anymore, here’s what to do:
  • As before, launch the Terminal application
  • Enter the following command:
    chflags nohidden /path/to/folder/
  • Close the Terminal
As an example, to unhide a folder on the users desktop named “Top Secret Folder” the command would be:
chflags nohidden ~/Desktop/Top Secret Folder/

Again, the folder will become immediately visible to the desktop. If you blocked the contents from Spotlight, you may want to remove it from there as well to be able to find and locate as usual.
There are apps you can use - some free - which do this w/out having to use Terminal, you know, such as InVisible.

Anyway, From what you say, you're trying to 'hide' an 'unused folder for a plug-in' :eek:?!?

I'm popping back into my DeLorean. Ta!

Be wise, be careful.
 
Sigh….

Here I am - writing from the 'future'.

Hopefully, you've resolved this ..thing, and hopefully, you stay away from Terminal - unless you know what you're doing.

Your 'problem's written very vaguely.

Let me see if I get what you're writing; for some reason, you're trying to 'hide' a folder', and - for some reason (?!?!) you're doing this through Terminal (have I got it, so far?)

Let me ask; why do you need to 'hide' this folder? So others - who've access to your 'outer don't see it/screw with it?

That's the only reason I can think of 'hiding' (you mean making 'invisible', correct?)

Ok - let's stay simple (yeah, I do know Terminal, very well, but, the best answer's always the simplest - learn that rule, and try to stick with, ok;)).

Highlight the folder, and hit 'get info' (⌘>'I'). You'll see a little 'lock' icon, on the bottom-right, and because you say you're not able to do…what you want with it, I'm guessing it's 'locked'. Click on it. It'll bring up a dialogue - asking for administrator/your password. Enter the password. The icon should now be an 'open lock'.

Now - if you want to use Terminal, do this;

  • Launch the Terminal, found in /Applications/Utilities/ or from Launchpad
  • Type the following command:
    chflags hidden /path/to/folder/
  • When finished, close out of Terminal
As an example, to hide a folder in the home directory named “Top Secret” the command would be:
chflags hidden ~/Top Secret/

Now that the folder is hidden, here is how to access it:
  • From the Mac OS X desktop, hit Command>Shift>G to bring up the “Go To Folder” window
  • Enter the same path to the folder as you used when hiding it:
Now you'll be inside the hidden folder, able to open, copy, move, and use the contained files and folders as usual.

To un-hide:
If you no longer want the folder to be hidden anymore, here’s what to do:
  • As before, launch the Terminal application
  • Enter the following command:
    chflags nohidden /path/to/folder/
  • Close the Terminal
As an example, to unhide a folder on the users desktop named “Top Secret Folder” the command would be:
chflags nohidden ~/Desktop/Top Secret Folder/

Again, the folder will become immediately visible to the desktop. If you blocked the contents from Spotlight, you may want to remove it from there as well to be able to find and locate as usual.
There are apps you can use - some free - which do this w/out having to use Terminal, you know, such as InVisible.

Anyway, From what you say, you're trying to 'hide' an 'unused folder for a plug-in' :eek:?!?

I'm popping back into my DeLorean. Ta!

Be wise, be careful.

Okay thanks for the help but this isn't the issue. I understand that unlocking the padlock down the bottom will give me access to it, I've done this. But see the problem is, even once I have unlocked it and I use the chflags hidden command, terminal comes back saying permission denied. Now see the checkbox in the get info window that says "locked" beside it, this is greyed out, I know it's not checked so shouldn't be locked, but every other folder I do this with, if that locked checkbox isn't greyed out I can use the chflags hidden command and it'll hide it.

And the purpose of hiding it is to simply hide me from seeing it in my documents folder, I do this with all the folders that I never access but are created by themselves through software.

Cheers
 
@akaPeach, please follow my instructions above. My guess is that the directory is protected in some way and the command will likely reveal that. It might be an immutable flag or an access control list. Finder does not show everything.
 
@akaPeach, please follow my instructions above. My guess is that the directory is protected in some way and the command will likely reveal that. It might be an immutable flag or an access control list. Finder does not show everything.

Thanks man I'll do that as soon as I get home from work and will update you.
 
@KALLT I hope this is safe to paste here but heres the output:

Code:
Anthonys-MacBook-Pro:~ Anthony$ ls -leO /Users/Anthony/Documents/Cakewalk
total 0
drwxr-xr-x  3 root  staff  - 102  1 Nov 22:50 CA-2A Leveling Amplifier
Anthonys-MacBook-Pro:~ Anthony$
 
@KALLT I hope this is safe to paste here but heres the output:

Code:
Anthonys-MacBook-Pro:~ Anthony$ ls -leO /Users/Anthony/Documents/Cakewalk
total 0
drwxr-xr-x  3 root  staff  - 102  1 Nov 22:50 CA-2A Leveling Amplifier
Anthonys-MacBook-Pro:~ Anthony$

Can you change the command to this:
Code:
ls -leOa /Users/Anthony/Documents/Cakewalk

I am guessing that the directory is owned by root as well, just like that file.
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.