Skip to content

Instantly share code, notes, and snippets.

View rrazgriz's full-sized avatar
💟

Raz rrazgriz

💟
View GitHub Profile
@rrazgriz
rrazgriz / UnityGuidRegenerator.cs
Last active July 31, 2022 00:51 — forked from ZimM-LostPolygon/UnityGuidRegenerator.cs
Generate new GUIDs for Unity editor assets in-place. Tested working on 2019.4.31f1. Use at your peril
// Regenerates GUIDs for Unity assets, and replaces all references to them in the scene.
// Drop into Assets/Editor or Assets/Scripts, Select Assets in project view, right click, `Regenerate GUIDs/Regenerate`
// `Regenerate GUIDs/Regenerate Recursive` will recursively regenerate for asset in any folders selected.
// Please know that this can break things, and only use it if you know you have a use case for changing GUIDs in-place.
using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.IO;
using System.Linq;