| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
| Name | Name | Last commit date | ||
|---|---|---|---|---|
$ info
$ which ls
output: /usr/bin/ls
$ link fileExist.txt newLinkFile.txt
$ ls -li
$ find / -inum 531188
$ find . -type f -links +1 2>/dev/null
$ls -p | grep -v / \
$ls -p | grep -v / | column
Using ls -p tells ls to append a slash to entries which are a directory, and using grep -v / tells grep to return only lines not containing a slash.
find . -maxdepth 1 -not -type d
ls -p | egrep -v /$
ls -F | grep -v /
Above command displays files, But it includes symlinks, pipes, etc. If you want to eliminate them too, you can use one of the flags mentioned below.
ls -F appends symbols to filenames. These symbols show useful information about files.
ls -F | grep -Ev '/|@|*|=|\|'
ls -F | grep -Ev '/|@|*|=|>|\|'
$ whatis dpkg
$ which column
$ dpkg -S $(which column)
$ ip address
$ umask
Lets assume your umask value is 002
octal to binary to mode
002 --> 010 --> -w-
Now create a file called: student.txt
Calculate the mode value beforehand:
rw- rw- rw-
--- --- -w-
----------------
rw- rw- r-- ==> 664
Now check the student.txt file permssion using ls -l or stat command $ stat student.txt
It reads data from the file and gives their content as output. It helps us to create, view, concatenate files
` > `cat -n file1.txt` > show content with line numbers`cat > file1.txt master-academy to save and close use ctrl+d
cat file1.txt > file2.txt overright one file by another
tac file1.txt content display in reverse order
cat file1.txt file2.txt view content from multiple files
cat file1.txt file2.txt > file3.txt combines multiple files output into a new file
cat file1.txt >> file2.txt to append the file1.txt to file2.txt
cat file1.txt | cat >> other.txt pipeing one file output appending into other file
timedatectl
ls -l /etc/localtime
timedatectl list-timezones
example time zone: Asia/Dhaka
sudo timedatectl set-timezone <your_time_zone>
sudo timedatectl set-timezone Asia/Dhaka
| Back | FazBrowse Home | New Git URL |