Linux - GeneralThis Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
I'm trying to make a hidden folder and everywhere says to start the name of the folder with a . I do and it changes the name to untitled folder, but I can still see it on my desktop. How to you actually hide the folder? Is the . Just for docs? Or is hiding it putting like a password on it?
putting it on your desktop for everyone to see, well everyone will see it. if it is hidden on your desktop even you will not be able to find it.
Place it in your home directory somewhere. It can be inside of a subdirectory as well. We see this because,
Code:
/home/user
is in itself a subdirectory already.
If you've used windows and hidden files and folders it is the same, it is nothing like putting a password on it, all one has to do is change the setting in the file manager and they will see any hidden file or folder.
even in a terminal all anyone has to do is issue
Code:
ls -a
that shows all files and folders even the hidden items a well. sticky bits kept one from gaining access to it for one. Permissions another, and one can go as far as putting a password on it too I suppose tough I've never had to do so. No need - no learn how to - applies for me there.
There is a hidden folder option in some of the Ubuntu file explorers. Where it is depends on your version of Ubuntu and your file explorer. For example, here is 14.04 hidden folders (with pictures):
Ok I correct my one statement on hidden folders on a desktop. I had to reboot into Slack where I got xfce4 installed, went into that and tried this out. Finding that with using XFCE4 I am able to create a hidden folder on my desktop both in the terminal and using a file manager, and they are in fact hidden on my desktop.
looking that the photo provided shows this. so the question is, what are you doing or using that is preventing you from doing the same?
what desktop are you running, and show your math please. (an American expression meaning show your work you did to get the results you got)
@hawksfan92 no offense taken here, why you want to do something is totally irrelevant to the how do I do something question.
I don't know how many times I've ran into that one, ask how do I do this, only to get back a bunch of why do you want to do that's? tell me or I will not help you, you have offended me by telling me that is none of my business to know. when in fact it is not any of the others business why because it has nothing to do with it.
one does not need to know why you want to search a directory, all they have to tell you is how to search the directory. that is it. for example.
How do I write a function to do something?
why do you want to know that?
what does that have to do with how to write a function to do something?
I have Ubuntu 15.10 and not really any of your business what I want the file for, no offense.
The reason I asked the purpose of your wanting to hide a folder is that the help and advice that can be given depends on the nature of the hiding that you want to implement.
If you're going to take that attitude, I would advise you, no offence, not to take part in internet forums such as this one where you will be routinely asked for information that will help people to resolve your problems.
@hawksfan92 no offense taken here, why you want to do something is totally irrelevant to the how do I do something question.
I don't know how many times I've ran into that one, ask how do I do this, only to get back a bunch of why do you want to do that's? tell me or I will not help you, you have offended me by telling me that is none of my business to know. when in fact it is not any of the others business why because it has nothing to do with it.
one does not need to know why you want to search a directory, all they have to tell you is how to search the directory. that is it. for example.
How do I write a function to do something?
why do you want to know that?
what does that have to do with how to write a function to do something?
I should elaborate on my questions above. I do not want to know, and don't care, what you are trying to hide.
What I would like to ascertain is to what extent you are trying to hide the directory i.e. from all users? from a particular user? so that one has to be root to see it? to merely allow or forbid directory listings? etc. etc. The solution will probably differ depending on what you want to do, and may even end up involving some form of encryption.
lets pick this human excrement apart. why not?
OP QUOTE
Quote:
Making hidden folders
I'm trying to make a hidden folder and everywhere says to start the name of the folder with a . I do and it changes the name to untitled folder, but I can still see it on my desktop. How to you actually hide the folder? Is the . Just for docs? Or is hiding it putting like a password on it?
header question:
Quote:
Making hidden folders
easy enough . just put a period before it. now it is hidden, I have no need to know why he wants to hide it. it is done. now he or she knows.
Op goes into describing what he is trying to do:
Quote:
I'm trying to make a hidden folder
no need to know why.
Op further goes on to describe how he is trying to accomplish this.
Quote:
and everywhere says to start the name of the folder with a .
no need to know why he wants to know how to make a hidden folder.
OP further goes on to tell us what the results are by doing so:
Quote:
I do and it changes the name to untitled folder, but I can still see it on my desktop.
he states that he does what he is told to by whatever means and the folder name changes to "untitled" and he is still seeing it on is desktop.
the need to know why he wants a hidden folder is still not present in order for him to do this.
OP then shifts away from the untitled folder being part of the results and directs the focus on only this.
Quote:
How to you actually hide the folder?
still no need to know why he needs to have a hidden folder.
then the OP makes a few stabs at the whys himself and shares them to the reader forming them into questions.
Quote:
Is the . Just for docs? Or is hiding it putting like a password on it?
still no need to know why he is trying to create a hidden folder. He is just trying to figure it out himself in the form of asking a question to someone else to get confirmation on his thoughts.
the answers to them added question now is,
Is the . Just for docs? NO
is a hidden folder like putting a password on it. NO.
still no need to know why he'd even want to put a password on a file or folder, it is self evident.
He does not want anyone else to see it or know it is there but him, hence that is why man created the ability to hide things.
He just wants to know how to hide something. The why or what it is they want to hide even, is no ones business but his or hers (that being the asker of how do I do something).
Where one would have to know the root pw to access it
That is very different than a traditional "hidden file", so it's very good that the question was asked and answered or you never would have received the proper response.
Now, one follow-up question, should non-root users be able to SEE the directory at all and simply not access it, or do you want for them to have no idea of its existence?
If they can see it but not access it, that just means you change the ownership of the directory to root, and remove permissions for other:
Code:
chown root:root mydir
chmod 700 mydir
If you don't even want them to be able to see it, then you'll need to hide it inside of another directory that regular users do not have permissions to traverse (such as /root).
lets pick this human excrement apart. why not?
OP QUOTE
header question:
easy enough . just put a period before it. now it is hidden, I have no need to know why he wants to hide it. it is done now he or she knows.
Op goes into describing what he is trying to do:
no need to know why.
Op further goes on to describe how he is trying to accomplish this.
no need to know why he wants to know how to make a hidden folder.
...
He just wants to know how to hid something. what and why is no ones business but his or hers (that being the asker of how do I do something).
See his latest response. It is very important that this question was asked and answered, or he never would have received an answer that satisfied his underlying goal.
The reason people ask probing questions like this is that the English language (all languages) is ambiguous. "Hidden" means different things to different people. The reasons for asking the question can help to clarify what is really being asked, and the responses can be adjusted to suit, which is EXACTLY what has happened in this thread.
Where one would have to know the root pw to access it
On Ubuntu, the simplest way would be just to create the directory as root. However any ordinary user could use sudo to access the directory unless you disable that capability for the users in question.
If the data is meant for your eyes only, then personally I would create an encrypted container for the data (using e.g. VeraCrypt) and mount it yourself only when you need access to it.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.