willowtreeapps / wist

A linter for BrightScript
Apache License 2.0
43 stars 11 forks source link

Best way to programmatically use wist #114

Closed saintberry closed 5 years ago

saintberry commented 5 years ago

Hey,

I'm looking for some guidance on the best way to programmatically use wist. I've got some gulp tasks setup for building and deploying. I'd like to have another task that's used to lint code before that happens.

I can use exec however that seems a little dirty when the code is all JavaScript. Any ideas or best practice?

Thanks!

nishtahir commented 5 years ago

A good example for how to do this programmatically is Ukor. You want to gather a list of files and then call

cliEngine.executeOnFiles(files)

The CLI engine will then log all the problems that it finds.