Directory Exploration
In this challenge, you'll put your basic Linux command-line skills to the test. Imagine you're a system administrator who needs to quickly gather information about the current working directory and its contents. Your task is to navigate the file system and retrieve specific details using only the pwd
and ls
commands. This challenge will help you become more comfortable with these fundamental Linux commands and improve your ability to gather directory information efficiently.
Tasks
- Determine the current working directory.
- List all files and directories in the
/home/labex/project
directory, including hidden files.
- Display the contents of the
/home/labex/project
directory in a long listing format, showing file permissions, owner, size, and modification date.
Requirements
- You must use the
/home/labex/project
directory as your working directory.
- You are only allowed to use the
pwd
and ls
commands.
- All commands must be executed in the terminal.
- You must use appropriate options with the
ls
command to achieve the required output formats.
- Don't use combinations of commands or pipes to achieve the desired output.
Example
Here's an example of what your output might look like (note that your actual output will depend on the contents of the directory):
$ ░░░
/home/labex/project
$ ░░░
. .. .hidden_file file1.txt file2.txt directory1
$ ░░░
total 16
drwxr-xr-x 2 labex labex 4096 Aug 7 10:00 directory1
-rw-r--r-- 1 labex labex 100 Aug 7 09:55 file1.txt
-rw-r--r-- 1 labex labex 200 Aug 7 09:58 file2.txt