LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This 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


Reply
  Search this Thread
Old 02-09-2017, 09:22 AM   #1
hawksfan92
Member
 
Registered: Jul 2014
Distribution: Ubuntu
Posts: 32
Blog Entries: 3

Rep: Reputation: Disabled
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?
 
Old 02-09-2017, 09:27 AM   #2
BW-userx
LQ Guru
 
Registered: Sep 2013
Location: Somewhere in my head.
Distribution: Slackware (15 current), Slack15, Ubuntu studio, MX Linux, FreeBSD 13.1, WIn10
Posts: 10,342

Rep: Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242
Code:
mkdir .mydir
that is a hidden dorectory
Code:
touch .myfile
that is a hidden file

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.

Last edited by BW-userx; 02-09-2017 at 09:36 AM.
 
Old 02-09-2017, 09:29 AM   #3
szboardstretcher
Senior Member
 
Registered: Aug 2006
Location: Detroit, MI
Distribution: GNU/Linux systemd
Posts: 4,278

Rep: Reputation: 1694Reputation: 1694Reputation: 1694Reputation: 1694Reputation: 1694Reputation: 1694Reputation: 1694Reputation: 1694Reputation: 1694Reputation: 1694Reputation: 1694
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):

http://askubuntu.com/questions/47083...n-ubuntu-14-04
 
Old 02-09-2017, 10:09 AM   #4
BW-userx
LQ Guru
 
Registered: Sep 2013
Location: Somewhere in my head.
Distribution: Slackware (15 current), Slack15, Ubuntu studio, MX Linux, FreeBSD 13.1, WIn10
Posts: 10,342

Rep: Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242
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)
Attached Thumbnails
Click image for larger version

Name:	Screenshot_HiddenFolders-on-desktop-2017-02-09_10-05-45.jpg
Views:	9
Size:	137.0 KB
ID:	24184  
 
Old 02-09-2017, 12:38 PM   #5
hydrurga
LQ Guru
 
Registered: Nov 2008
Location: Pictland
Distribution: Linux Mint 21 MATE
Posts: 8,048
Blog Entries: 5

Rep: Reputation: 2925Reputation: 2925Reputation: 2925Reputation: 2925Reputation: 2925Reputation: 2925Reputation: 2925Reputation: 2925Reputation: 2925Reputation: 2925Reputation: 2925
For what purpose(s) do you want to make a hidden folder? Hidden from whom, and in what circumstances?

Could you please provide details on your distro and version. Thanks.
 
1 members found this post helpful.
Old 02-09-2017, 12:55 PM   #6
hawksfan92
Member
 
Registered: Jul 2014
Distribution: Ubuntu
Posts: 32

Original Poster
Blog Entries: 3

Rep: Reputation: Disabled
I have Ubuntu 15.10 and not really any of your business what I want the file for, no offense.
 
Old 02-09-2017, 12:59 PM   #7
BW-userx
LQ Guru
 
Registered: Sep 2013
Location: Somewhere in my head.
Distribution: Slackware (15 current), Slack15, Ubuntu studio, MX Linux, FreeBSD 13.1, WIn10
Posts: 10,342

Rep: Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242
@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?

Last edited by BW-userx; 02-09-2017 at 01:05 PM.
 
Old 02-09-2017, 01:35 PM   #8
hydrurga
LQ Guru
 
Registered: Nov 2008
Location: Pictland
Distribution: Linux Mint 21 MATE
Posts: 8,048
Blog Entries: 5

Rep: Reputation: 2925Reputation: 2925Reputation: 2925Reputation: 2925Reputation: 2925Reputation: 2925Reputation: 2925Reputation: 2925Reputation: 2925Reputation: 2925Reputation: 2925
Quote:
Originally Posted by hawksfan92 View Post
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.
 
2 members found this post helpful.
Old 02-09-2017, 01:43 PM   #9
hydrurga
LQ Guru
 
Registered: Nov 2008
Location: Pictland
Distribution: Linux Mint 21 MATE
Posts: 8,048
Blog Entries: 5

Rep: Reputation: 2925Reputation: 2925Reputation: 2925Reputation: 2925Reputation: 2925Reputation: 2925Reputation: 2925Reputation: 2925Reputation: 2925Reputation: 2925Reputation: 2925
Quote:
Originally Posted by BW-userx View Post
@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?
Have you never heard of the XY problem?
 
1 members found this post helpful.
Old 02-09-2017, 01:51 PM   #10
hydrurga
LQ Guru
 
Registered: Nov 2008
Location: Pictland
Distribution: Linux Mint 21 MATE
Posts: 8,048
Blog Entries: 5

Rep: Reputation: 2925Reputation: 2925Reputation: 2925Reputation: 2925Reputation: 2925Reputation: 2925Reputation: 2925Reputation: 2925Reputation: 2925Reputation: 2925Reputation: 2925
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.
 
Old 02-09-2017, 02:09 PM   #11
hawksfan92
Member
 
Registered: Jul 2014
Distribution: Ubuntu
Posts: 32

Original Poster
Blog Entries: 3

Rep: Reputation: Disabled
Where one would have to know the root pw to access it
 
Old 02-09-2017, 02:14 PM   #12
BW-userx
LQ Guru
 
Registered: Sep 2013
Location: Somewhere in my head.
Distribution: Slackware (15 current), Slack15, Ubuntu studio, MX Linux, FreeBSD 13.1, WIn10
Posts: 10,342

Rep: Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242
Quote:
Originally Posted by hydrurga View Post
Have you never heard of the XY problem?
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).

Last edited by BW-userx; 02-09-2017 at 02:31 PM.
 
Old 02-09-2017, 02:14 PM   #13
suicidaleggroll
LQ Guru
 
Registered: Nov 2010
Location: Colorado
Distribution: OpenSUSE, CentOS
Posts: 5,573

Rep: Reputation: 2142Reputation: 2142Reputation: 2142Reputation: 2142Reputation: 2142Reputation: 2142Reputation: 2142Reputation: 2142Reputation: 2142Reputation: 2142Reputation: 2142
Quote:
Originally Posted by hawksfan92 View Post
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).
 
2 members found this post helpful.
Old 02-09-2017, 02:16 PM   #14
suicidaleggroll
LQ Guru
 
Registered: Nov 2010
Location: Colorado
Distribution: OpenSUSE, CentOS
Posts: 5,573

Rep: Reputation: 2142Reputation: 2142Reputation: 2142Reputation: 2142Reputation: 2142Reputation: 2142Reputation: 2142Reputation: 2142Reputation: 2142Reputation: 2142Reputation: 2142
Quote:
Originally Posted by BW-userx View Post
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.
 
2 members found this post helpful.
Old 02-09-2017, 02:19 PM   #15
hydrurga
LQ Guru
 
Registered: Nov 2008
Location: Pictland
Distribution: Linux Mint 21 MATE
Posts: 8,048
Blog Entries: 5

Rep: Reputation: 2925Reputation: 2925Reputation: 2925Reputation: 2925Reputation: 2925Reputation: 2925Reputation: 2925Reputation: 2925Reputation: 2925Reputation: 2925Reputation: 2925
Quote:
Originally Posted by hawksfan92 View Post
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.
 
1 members found this post helpful.
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] How to remove all hidden directories and folders, and only hidden directories and folders rm_-rf_windows Linux - General 5 04-12-2016 07:28 AM
bash script to create folders including making recursive folders.... linux-bandit Linux - Software 8 11-28-2009 01:50 AM
ls -R - without hidden folders j0hnsmith Linux - Newbie 2 09-27-2009 09:46 PM
Cleaning Hidden Folders Raymond C. Glassford Mandriva 3 07-01-2008 12:10 AM
hidden folders tenmiles Linux - General 5 11-23-2004 02:37 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 02:07 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration