Ways to see what a command would do, without actually carrying out the action.

.gitignore

To list the files that don't match .gitignore:

To list the files that do match .gitignore:

To list both together:

built-in

Commands that have a good option built-in: