How to find the options in if conditions of shell

bash, shell

Solution

You can do `help test` which will show most of the options accepted by the `[[` command.

You can also do `help [` which will show additional information. You can do `help [[` to get information on that type of conditional.

Also see `man bash` in the "CONDITIONAL EXPRESSIONS" section.

Problem

In one of my shell script, I'm seeing ``` if [[ ! -d directory1 || ! -L directory ]] ; then ``` What does `-d` and `-L` option mean here? Where can I find information about the options to use in an `if` condition?

Original source

Related problems