-
-
Notifications
You must be signed in to change notification settings - Fork 22k
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
Update script documentation removed files on startup #95965
Update script documentation removed files on startup #95965
Conversation
366b66b
to
2bf8a42
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The code makes sense to me. I'd like to see an added comment but it isn't critical! :)
Thanks for putting this together so fast!
2bf8a42
to
3698124
Compare
Actually, I just noticed there's a function called if (!FileAccess::exists(file)) {
//was removed
_delete_internal_files(file);
if (cpos != -1) { // Might've never been part of the editor file system (*.* files deleted in Open dialog).
...
if (ClassDB::is_parent_class(fs->files[cpos]->type, SNAME("Script"))) {
_queue_update_script_class(file, fs->files[cpos]->type, "", "", ""); ///////////// This here might regen docs?
if (!fs->files[cpos]->script_class_icon_path.is_empty()) {
update_files_icon_cache = true;
}
} Perhaps it is worth collecting all the script files in a |
This method skip files that are not in the FileSystem because of the |
You know best! I just noticed the method and thought it might be relevant! Exciting about the progress bar too! :) |
3698124
to
1c3bc2f
Compare
Thanks! |
This PR is a prerequisite for #95821
It will adds the removed files in
update_script_paths_documentation
on first scan by comparing the file cache with the files on disk. It's important for #95821 so the removed scripts could be removed from the documentation.Currently,
update_script_paths_documentation
does not remove documentation if the file does not exists on disk it will be implemented in #95821.I tested with a project that has 3000 scripts files. After removing the files while the editor is closed and starting it, the method
EditorFileSystem::_process_removed_files_first_scan
tooks 22ms to find the 3000 missing scripts.This is a team work with @anvilfolk