- Home /
How to change code file associations in unity?
Whenever I open to edit a .cs file in Unity, it opens UniSciTE instead of the editor I have associated with this filetype in my OS. How can I change this? I cannot find this setting anywhere in Unity.
I would like to use MonoDevelop or Visual Studio to edit these files, but being unable to change this behaviour makes it quite a hassle.
Answer by Ashkan_gc · Feb 08, 2010 at 04:01 PM
go to edit/preferences and then in general tab choose the "external script editor" that you want.
Answer by davebuchhofer · Feb 08, 2010 at 03:58 PM
Most of this entry is out of date nowadays, but the last section details how to use a batch file to open up files directly in visual studio or unitydevelop
Wiki: Setting up Visual Studio
as an example, below is my dos batchfile, that i have set up for both home and work, and to open .js/.shader in flashbangs unitydevelop, and visual studio express for .cs files, for accurate syntax highlighting in VS express, you should open the vs solution first
set classExecPath="C:\classexec\classexec.exe" set UnityDevelopPath="C:\Program Files\UnityDevelop\Unitydevelop.exe"
GOTO :%~x1
:.cs ECHO "CS PATH" %classExecPath% %1 --class .cs GOTO :endscript
:.js ECHO "JS PATH" %UnityDevelopPath% %1 GOTO :endscript
:.shader ECHO "SHADER PATH" %UnityDevelopPath% %1 GOTO :endscript
:endscript
Your answer
Follow this Question
Related Questions
The name 'Joystick' does not denote a valid type ('not found') 2 Answers
Limiting EditorGUI.ObjectField() to Prefabs only? 2 Answers
How do I break apart an object? 2 Answers
[Editor] Find all objects with a particular script in the scene 1 Answer
Webplayer: Why can't we call private member function from a constructor? 0 Answers