Skip to content

Embed URL

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
A simple C# builder for Sublime Text 2. Accompanying C# builder definition here: https://gist.github.com/1387543
:: Assumptions:
:: - Sublime Text has set the working directory and both the source and executable files
:: are in that directory
:: - The script is only capable of handling simple C# apps that do not reference 3rd-party
:: libraries
:: Inputs from Sublime Text
:: %1 - The full path and filename of the source file to build
:: %2 - The name of the executable file
@SET SRC_FILE="%1"
@SET EXE_NAME="%2"
:: Set up build environment. Change this as necessary depending on the version
:: of Visual Studio you wish to use.
@CALL "%VS90COMNTOOLS%vsvars32.bat"
csc %SRC_FILE% /nologo /debug:full /platform:x86
@IF errorlevel 1 GOTO end
:: Execute compiled binary if build was successful.
@ECHO.
@ECHO Executing %EXE_NAME%:
@ECHO.
@%EXE_NAME%
:end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.