Description
Update: after #102 have added multiple entry points to the checker. However it is not fully wired up to Ezno's CLI with:
Lines 170 to 172 in 1aa77e2
The next part (that you can contribute to):
- Get a
Vec<PathBuf>
from a input path.- This could be a glob pattern or just a comma separated list
- Should consider whether this method will work with the notify crate. While
check --watch
isn't currently implemented, it would be good if this addition can work with a watch mode in the future
Note I have not checked side-effect edge cases in #102
Currently there is only one entry path. OP wants to check all files in the directory. Note each entry point also type checks its imports, so this isn't necessary for checking imports and exports.
Rather than running entry_points.for_each(|path| check_project(path, ...))
this needs to be built into the internal ModuleData
. So it should be callable as check_project(vec![...])
.
Things to think about
- Side effects in modules (want to reuse some existing data, but make it distinct)
- How to get a
Vec<PathBuf>
from the glob passed to the CLI- How this works in the CLI watch mode
Discussed in #80
Originally posted by o-az November 11, 2023
How can I run oxidation-compiler
to typecheck multiple files by passing a glob string / directory path?
Works:
npx oxidation-compiler@latest check src/file.tsx
None of these commands check all files:
npx oxidation-compiler@latest check src/*.tsx
npx oxidation-compiler@latest check src/
npx oxidation-compiler@latest check src/*