My project generates several executable files which follow the usual Unix convention of not having an extension on their name. How do I exclude those files from my project? I’ve tried a couple of things in the “file_exclude_patterns” setting, but haven’t succeeded.
Exclude files without extensions from project?
Please list the file name in question, and the filter that you’re trying to use to exclude it.
It’s not just one file. That’s easy. It’s about a dozen files, so I’d prefer not to exclude each one individually.
The files have names like:
tfloat
tdouble
tlong_double
there are corresponding files with a .c extension:
tfloat.c
tdouble.c
tlong_double.c
that should not be excluded. If I wanted to exclude them, the expression would be “*.c”. Haven’t figured out how to say “doesn’t have a ‘.’”.
Unfortunately there’s no wildcard that will match all files with no extension, the only option is to use a set of patterns along the lines of “tfloat”, “tdouble”, “tlong_double”].
That’s what I figured. Thanks.
Oh, and a minor suggestion: grep has -v, to return lines that don’t match the regular expression. Maybe something similar for matching in the exclude_xxx contexts? “!.”?
Works in ST2/ST3
{
"path": ".",
"file_include_patterns": ["*.*"],
"file_exclude_patterns": ["*.sublime-project"], // or anything you like
}