Page 1 of 1

Only lint open files?

PostPosted: October 23rd, 2018, 12:57 pm
by dutchie027
First of let me say that the VS Code plug in is awesome. My only question, I have a lot of .php files in my workspace due to multiple repos and directories and each time I open the workspace, it wants to lint every single file, resulting in tons of problems in the far right pane. Is there any way to restrict the linter to only sense check the open files?

Re: Only lint open files?

PostPosted: October 23rd, 2018, 6:42 pm
by mhpcc
Only linting open files would be a terrible, terrible experience for you. Because either you open all files, or you get zero useful info in the first place.

Intellisense/linting info should be cached and only reloaded on changes, which is what I've asked int he post just below yours.

Re: Only lint open files?

PostPosted: October 23rd, 2018, 6:59 pm
by dutchie027
I totally disagree. When I look over at the right hand"Problems" pane, I only care about the information for my open files, I don't care about all 400 other files in my repository or even workspace. Right now, the scroll bar goes on for miles and miles (>2000 problems) about files I don't have open nor do I intend to open any time soon. I have one file open which has two issues, and at first glance, that's impossible to see/deduce.

Re: Only lint open files?

PostPosted: October 25th, 2018, 12:17 pm
by mhpcc
Oh, so you only mean warnings and errors, not static code analysis and intellisense as a whole. I misunderstood you there, sorry.

Re: Only lint open files?

PostPosted: October 29th, 2018, 2:39 pm
by dutchie027
I don't mind if the intellisense shows me troubelsome files in the tree view by coloring them (as it does now) but I don't want to see all of the extended output of errors, warnings, etc from every file (in the right pane) - only open files in the editor.

Re: Only lint open files?

PostPosted: November 6th, 2018, 10:10 am
by Miloslav Beno
Hi guys,

We have added two options in the latest release for VSCode :
- files.exclude - You can remove certain files and folders completly from the project
- php.problems.exclude - You can exclude files from code validation, but they will be available for Intellisense engine

Thank you,

Re: Only lint open files?

PostPosted: November 6th, 2018, 12:46 pm
by Miloslav Beno
May I ask what kind of errors do you have in your project? ty problems.exclude setting is indented mainly for vendor or other vendor's libraries they you don't want to analyse. Your project ideally shouldn't have the issues.

Thanks,