-
Notifications
You must be signed in to change notification settings - Fork 2.2k
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
tweak(server): ignore resources that have a name starting with '.' in resource scan #3001
base: master
Are you sure you want to change the base?
Conversation
Why not ignoring all folders starting with a dot ? |
Since resource scan is a critical component, I wouldn't want to change something there unless there was a specific desire to do so, like there is with |
Also will be great to add .vscode : ) |
Wouldn't it be better (if possible) to leave this up to a server convar? Being able to define different types of files or folders to ignore? I'm sure this could cause issues but if used correctly potentially not. |
I think the first server resource checks is done before server convars is settled, also seems a bit unnecessary for the vast majority of servers. |
Wouldnt it be much better to add a file like .gitignore where we can define content that should be skipped? if it doesnt exist then use the current defaults? |
It would probably just be better to ignore any file starting with a |
Definetly the best approach to just ignore all the folders starting with |
This should probably be specifically done for directories, not every file. |
True, lemme fix that real quick. |
0b61f37
to
e05bd58
Compare
@tabarra If/when this gets merged, you'll eventually want to update https://github.com/tabarra/txAdmin/blob/8cbc767aa24e614fe2dc801810cb3ea58df282fd/core/extras/serverDataScanner.ts to mirror this change. |
You've messed up your PR and are reverting changes to the FiveM repo since your initial commit was made. |
e05bd58
to
0ec3c8f
Compare
More specifically it should ignore all childs inside a directory starting with "." and any files starting with ".". |
@jellyton255 Thanks for the heads up, but my scanner implementation will be deprecated soon, as I'll switch to the new ScanResourceRoot native: |
Goal of this PR
Like the .git folder, we ignore the .github folder from the resource scan so git repos with a .github folder do not result in a warning during a resource scan.
How is this PR achieving the goal
Adding an additional check to the resource scan loop so that resources with the name ".github" are skipped.
This PR applies to the following area(s)
Server
Successfully tested on
Platforms: Windows
Checklist