My homework asked me to find what ls ..
does.
I tried to search the internet but I couldn't find any answer to the question.
Does someone know what this command does?
..
is an entry in the current directory that refers to the parent of the current directory. It's not a special convention used just by ls
. For example:
$ cd /usr/bin
$ pwd
/usr/bin
$ cd ..
$ pwd
/usr
$ [ -d .. ] && echo "It's a directory"
It's a directory
$ stat ..
<output specific to your installed version of stat>