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
folder_exclude_patterns is excluding all project folders named Settings #1895
Comments
Sublime Text is ignoring all folders names Settings everywhere. Issue: folder_exclude_patterns is excluding all project folders named Settings sublimehq/sublime_text#1895
I suspect the pattern is matched against the entire path, so you could try something like |
This But not the nested folder: Currently doing: {
"folders":
[
{
"path": ".",
"folder_exclude_patterns":
[
"Settings",
],
},
]
} Will make Sublime Text to ignore both folders, not only the root folder |
This is a bug on Sublime Text, which is putting the glob pattern {
"folders":
[
{
"path": ".",
"folder_exclude_patterns":
[
"Settings",
],
},
]
} As this: {
"folders":
[
{
"path": ".",
"folder_exclude_patterns":
[
"*Settings",
],
},
]
} It only should interpret |
I experimented a bit. The following is what I could come up with.
Now things get more complicated. All the following situations contain either
This still doesn't fit all the observed results, but it's an estimation for now. What I don't understand is why The observed results are as follows and could be used to write a test suite, for example:
|
Thanks for the insights! I managed to fix this prepending The {
"folders":
[
{
"path": ".",
},
]
} So to ignore some folder I would use: {
"folders":
[
{
"path": ".",
"folder_exclude_patterns":
[
"./Settings/*",
],
},
]
} To ignore a root folder not depending on the current folder Currently I did was: {
"folders":
[
{
"path": ".",
"folder_exclude_patterns":
[
"Data/Settings",
],
},
]
} Where |
I suggest opening a new issue for the |
I ran into this issue today. Behavior seems very counter-intuitive. Is there any documentation on what format these "patterns" should be in, because it doesn't seem to be glob. |
As @danny-andrews pointed out, documentation should be provided. The projects page at the official documentation is starving, and hunting on Google for clues on how to use settings and patterns will inevitably result in forums posts and Issues which might not mirror the current state of latest ST3. Please, use the official ST3 documentation to actually store always up to date (and detailed) info on how to use settings and features. |
I believe the experiments I presented earlier in this issue are the most detailed documentation available currently. |
After working through this over 2 hours, I went back and looked at the documentation. Aside from knowing variable names, it almost entirely fails to document most aspects of its operation and the relationship of project, folder, and patterns. Although it is still useful, its inability to handle pretty simple, common directory layouts is surprising. I concur with those remarking that it is counter-intuitive. It is. Can a reasonably experienced engineer figure the quirks out solely with the documentation provided by sublime? Pretty sure the answer is not within a reasonable period of time. I encourage improvements to the documentation. Further, guidance on specific common issues and strategies to resolve them. In the documentation. Or make a better glob. Something. Looks like this or variants of it has confused and confounded people going on 6 years now. |
As of build 4067, patterns can use Additionally, documentation will be posted soon that outlines the file pattern features and behavior. There are some slight behavior tweaks between 4067 and all previous builds, and the documentation will include info about both. |
Summary
On my Sublime Project I got:
So it should exclude the top level root folder
Settings
, but it is ignoring all folders everywhere on the project structure which is namedsettings
orSettings
.I tried to do
/Settings
,./Settings
, but then it stop ignoring all the folders, including the root folder namedSettings
.Related:
Expected behavior
Only ignore the root folder when set
./Settings
or/Settings
on my .sublime-projectActual behavior
Does not ignore the root folder when set
./Settings
or/Settings
on my .sublime-projectSteps to reproduce
My.sublime-project
:Settings
on the top levelMyFolder/settings
./Settings
folder and nestedMyFolder/settings
folder.It only should ignore the top level
Settings
folder. If I want to ignore nested folders, I should use*/Settings
or be able to ignore only the top level using.Settings
or./Settings
or/Settings
Environment
dpi_scale
used in ST 1.0The text was updated successfully, but these errors were encountered: