Please use the search feature of these forums. Search for “rename project”.
EDIT: or do you mean you have a standalone KiCad schematic file without a KiCad project?
In particular see FAQ renaming a project
This is a task that should be a lot simpler to do, something to be pushed as a wishlist item after V5 release.
As near as I can tell from that thread, it’s basically saying “just rename the files,” which is what the OP did. Just renaming the files always works for me, so I’m unclear what the OP is doing wrong.
The rescue lib is referenced within the project file. so changing it’s name means you need to touch the project file. (That is what i meant with “correct everything that has to do with these libs”)
If you do not change it’s name you will create a second rescue file if you need to again rescue symbols in the future. (As kicad will then use the new project name)
Only if the regex used for the replacement is correct. (And only if the original poster knew about that.)
Any mistake and you might end up with invalid files. (Especially if the old project name by accident had parts in it that are used elsewhere in the files.)
So my guess is that a simple text replace might not always result in the expected result. You need to be smarter about it and ensure that only the things that need to be touched are changed.
Have we missed one obvious solution? Leave the file names of cache and rescue libs untouched, and there’s no need to edit files. Has someone tried that, would the project still work?
I touched on that already. At least for the rescue lib there will be a second one generated if new symbols need rescuing.
For the cache lib i fear, that one really needs to have the same name as the project. (Again because kicad will automatically generate one with that name if it does not find one.)
I realize that probably nothing of this discussion helped the original poster. If the problem persists, we need more information. What version of KiCad? Did you copy the project to another location and then tried renaming the new one? Or there might be something else. It would be easiest if you could share the whole project.