Ignore custom directories when scanning for files.

When scanning for files the user can now optionally specify a list of
paths to ignore.