How do I use Scopes?

I have tried and read the Help file and tried some more, and I just can't figure it out how to create these. It says there is a Project Tree view in the Scope Editor, but I don't even have that.



Attachment(s):
scope_problem1.JPG
0

Ok, found the Project Tree. Show included files was selected (I didn't do that.) Now, it's showing me to create this.

Right off the bat, it shows me this syntax:

file[Intranet_TEAM1]:library/classes/apps/Collections.php

I didn't see this in the Help file anywhere. Only src[], lib[], test[]

0

Ok, now I see file:

help you specify whether the desired set is located in the source files, library classes or test code in the form of location modifiers src:, lib:, file:, or test:. For example, the following scope src:com. intellij.OpenApi.* implies all classes under the source root in the com.intellij.OpenApipackage, excluding subpackages.

Still, I don't know what the heck that means. Think we can get some examples in the help file? Is this a syntax used elsewhere?

This, com.intellij.OpenApi.MyClass, is Java...not PHP. Why is this an example? Am I missing something?

0

lol, I just saw this:

Module Modifiers
help you narrow down the scope by specifying the name of the related module in the form src[module name]:<E>. lib[module name]:<E>, or test[module name]:<E>. For example, the following scope src[MyJavaModule]:com.intellij.OpenApi.* implies all classes under the source folders related to the module MyJavaModule in the package com.intellij.OpenApi excluding subpackages.

Did y'all steal this from some Java help file?

0

Well, while the Scopes are platform feature only Java users dig into it more than "include recursively" on some lib folders or logical modules so we have not written specific help for other languages.

Anyway anything beyond basic file/folder patterns is not yet supported for PHP.

BTW What exactly are you trying to achieve with scopes in your project? We plan to put some effort in this are in post 2.0 so we're pretty interested in user stories.

0

Some of the background is described in this thread javascript:;. We have a huge project and when a user is working within that project, the Scopes features looks to be useful in allowing me to quickly check for errors in my own work and also, I act as the gatekeeper for other developers work. So, for use in the Inspection process is what I intend to use it for now. However, it would be awesome to be able to use with revision comparison: http://youtrack.jetbrains.net/issue/WI-3844?

0

I believe that what goes in between the brackets is different for file: type scopes. Whatever is referred to, it is not a "module." I would like to think that in "file[root]:," the "root" is not a module. Nor is it the project root as a whole. Rather, I believe it is what I suggest calling a "folder collection," which coincidentally has the same name and root folders as a project. I would like to see the concept of a "Custom Folder Collection" that, above all, supports nested roots. It would greatly simplify the verbosity of the scopes I have to create and also provides me a convenient way of adding more folders to match scope patterns against in the future. For example, "root" has a subfolder "css" and another subfolder "js", and its children "child1" and "child2" have subfolders "css" and "js". If one day I notice that "child3" has been created with subfolder "css", but subfolder "js" will not be included for another two months, I can use one set of scope patterns to automatically include it if it is added to "child3."

file[Collection1]:css//*||file[Collection1]:js//*

Stuart

0

请先登录再写评论。