GitHub - QCPolmer/Blender-3d-remove-duplicate-materials-in-scene: Run this script from a scene and it will replace all materials with a '.001' or whatever with the material without the number after it. Basically, it is for
Clean material slots that are not used. — Right-Click Select
Data-Blocks — Blender Manual
All Material List - Released Scripts and Themes - Blender Artists Community