Can a Debug.Log message open the file explorer automatically?

Is there a way to open a certain folder just by clicking to a file path in the console that have been logged with Debug.Log?

For example in linux notation:

Debug.Log("~/home/user/.config/unity3d/MyCompany/MyGame/Unity/123456asdf/Editor/Analytics/ArchivedEvents)

I found this thread that could shed some light: c# - Is there a way to use hyperlink in Unity’s console? - Stack Overflow

Unfortunately it seems not. Even the comment that Dale posted at the bottom doesn’t seem to work. I imagine that if you really wanted this, you would have to write a custom editor that you can log things to and supports links to folders.

I don’t imagine a custom editor like this would be to complicated, but it seems a little unnecessary. But that all depends on what you are trying to do.

1 Like