Home  >  Article  >  Operation and Maintenance  >  How to hide files under Linux

How to hide files under Linux

angryTom
angryTomOriginal
2020-03-11 14:58:0311554browse

This article mainly introduces the method of hiding files under Linux, which has certain reference value. Friends in need can refer to it. Let’s take a look at a simple method to hide files in Linux.

How to hide files under Linux

How to hide files under Linux

1. Hidden files/directories

Hidden files in Linux file systems are the result of a long-standing bug in the Unix operating system. After a while, many people adopted this functionality and considered it a feature. The method of hiding files or directories is much simpler than on Windows. To hide an entire file in Linux, just rename the file and put some text in front of it.

How to hide files under Linux

The specific method is as follows:

1) Find a file or directory you want to hide using the file manager and select it .

2) Press F2 (or right-click and select "Rename").

3) Next, place a "." in front of the file name.

Since most file managers hide hidden files by default, the renamed file or directory is now invisible. Note that files placed in hidden directories will also be hidden by default.

2. View hidden files and folders in the terminal

To view these files, first use cd to enter the specific directory where you have hidden files/folders. Next, use the command below to display all files, whether visible or hidden.

ls -a

ls command is used to display all projects in the current directory, but not hidden projects. To view hidden items, the -a parameter is required.

How to hide files under Linux

3. View hidden files and folders in the file manager

Use the keyboard shortcut "Ctrl H" Show/hide [hidden files].

How to hide files under Linux

This article comes from the PHP Chinese website, Linux system tutorial column, please continue to pay attention to this column for more related tutorials!

The above is the detailed content of How to hide files under Linux. For more information, please follow other related articles on the PHP Chinese website!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn

Related articles

See more