Sunday, September 30, 2012

Sublime Text as Code Editor (1) Compile

Sublime Text as Code Editor (1) Compile:
I have been making a move to sublimetext2 in linux as my primary development environment. This series of posts will look at the editor and various tweaks and addons that are needed to get working with C# code. There are tons of tutorials about sublime online but none seem to cover setting up a C# environment. To start with let’s learn how to be able to compile code.
Go to tools->build->new build. A file will open. Drop in:
{

“cmd”: ["xbuild"],

“path”: “/opt/mono/bin/”,

“working_dir”: “${project_path:${folder}}”,

“file_regex”: “^ (.*)\\(([0-9]*),([0-9]*)”

}
Then save this file named xbuild.
Note I run mono trunk built from source which is why my prefix is /opt/mono. Now when you have a folder open for your project it will run xbuild in the root of that folder. This only works if there is only a single solution in the root folder. To build use ctrl+b or f7.
In the next post we will look at switching between code and basic navigation.


DIGITAL JUICE

No comments:

Post a Comment

Thank's!