Please note that brackets have no special meaning to the shell.
Please note that brackets have no special meaning to the shell.
But as far as I can see, using a close-bracket as the first character in a command is safe, since it cannot be treated as part of such a pattern. Open-bracket (without a matching close-bracket) would work in many shells, but will get you a "bad pattern" error in zsh.
Together with "*" and "?", the brackets "[" and "]" have been used by the UNIX shell since some of its earliest versions (already many years before the Bourne shell) in pattern matching for pathname expansion (globbing).
For example, if you have in a directory 3 files named "file1", "file2" and "file3", then
"ls file?" will output
file1 file2 file3
while "ls file[13]" will output
file1 file3