Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Question / Improve documentation] Exclude/include directory in report but not in analyzer. #120

Open
Yivan opened this issue Aug 5, 2019 · 2 comments
Labels

Comments

@Yivan
Copy link

Yivan commented Aug 5, 2019

Hello,

Thanks for this wonderful and powerfull program, and for sharing it with us.
I am in the process of testing it on a complexe symfony 4 application.
I would like to have report/result only on our bundles in src/, for instance src/MyBundle.
But this bundle depend of many classes in vendor/ and some other directory outside src/.

How can I set the anlaysis to covert reports only on src\MyBundle, but using all the files available inside the project (vendor/ and some others secific to the project) ?

Running analysis only on src/MyBundle defeat the purpose of AST as all the dependancies are not availables for the analysis. And running it on all the project brings report for all the files of the project (and we want only our bundle).

I readed carefully the documentation, and exclude/include dir seems to exclude/include them directly before the analysis pass.

Is there a way to do this ? If yes, documentation should mention it, i think it is a very important point.

Thanks a lot!

@exakat
Copy link
Owner

exakat commented Aug 19, 2019

Hi Yivan,

The default behavior of Exakat is to run analysis only on the intented files (here, src/MyBundle), but it will always take all files into account, in particular to weed out definitions (classes, interfaces, functions...) that are available but ignored by configuration.

the important point here is to have the code : if the framework is configured via composer, but not installed, exakat will not install it by itself. It only relies on the available code, or on extensions to provide context information.

I agree this requires some more details in the documentation.

@Yivan
Copy link
Author

Yivan commented Aug 19, 2019

Hi @exakat Thanks for your reply.
You mean, when i create a project in exakat, it only send back errors of src/* ?

I mean, typicaly i add as project the root folder of the project.
Depending project sometimes it is "classic" synfony project (with directories src, vendor, etc.).
Sometimes it is some old prj (zend 1 for instance having code in "application/" directory, and externe library on "library/").
How exakat knows it must exclude "library/" from code reporting ? (but parse it for dependencies).

I mean more generaly as all is automatized, how exakat know which are the folder which must be included in errors reports ?
A dedicated parameters should exists to decided wich directories should be included in the error reports. Do i miss something ?

Thansk!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants