Only lint open files?

PHP Tools [?] extends Visual Studio with set of advanced features to work more efficiently with PHP code.

Only lint open files?

Postby dutchie027 » October 23rd, 2018, 12:57 pm

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?
dutchie027
 
Posts: 3
Joined: October 23rd, 2018, 12:55 pm

Re: Only lint open files?

Postby mhpcc » October 23rd, 2018, 6:42 pm

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.
mhpcc
 
Posts: 22
Joined: October 19th, 2018, 10:46 pm

Re: Only lint open files?

Postby dutchie027 » October 23rd, 2018, 6:59 pm

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.
dutchie027
 
Posts: 3
Joined: October 23rd, 2018, 12:55 pm

Re: Only lint open files?

Postby mhpcc » October 25th, 2018, 12:17 pm

Oh, so you only mean warnings and errors, not static code analysis and intellisense as a whole. I misunderstood you there, sorry.
mhpcc
 
Posts: 22
Joined: October 19th, 2018, 10:46 pm

Re: Only lint open files?

Postby dutchie027 » October 29th, 2018, 2:39 pm

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.
dutchie027
 
Posts: 3
Joined: October 23rd, 2018, 12:55 pm

Re: Only lint open files?

Postby Miloslav Beno » November 6th, 2018, 10:10 am

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,
Miloslav Beno │ DEVSENSE s.r.o. │ @miloslavbenomiloslav@devsense.com
User avatar
Miloslav Beno
 
Posts: 1252
Joined: January 7th, 2012, 8:36 pm

Re: Only lint open files?

Postby Miloslav Beno » November 6th, 2018, 12:46 pm

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,
Miloslav Beno │ DEVSENSE s.r.o. │ @miloslavbenomiloslav@devsense.com
User avatar
Miloslav Beno
 
Posts: 1252
Joined: January 7th, 2012, 8:36 pm


Return to PHP Tools

Who is online

Users browsing this forum: No registered users and 38 guests

cron

User Control Panel

Login

Who is online

In total there are 38 users online :: 0 registered, 0 hidden and 38 guests (based on users active over the past 5 minutes)
Most users ever online was 256 on March 28th, 2024, 9:42 am

Users browsing this forum: No registered users and 38 guests