An easy-to-use collection of MS Build tasks to help improve your build process.
C# JavaScript
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
src
.gitignore
.travis.yml
LICENSE
README.md

README.md

EasyBuild

An easy-to-use collection of MS Build tasks to help improve your build process.


Tasks

  • StartWebProjectTask: when you need to start some one of your web projects during the build process (useful to generate some client library for your web apis).

  • Resources2JSTask: serialize resource files with localized labels to JS files.


Usage

Follow the steps below to put EasyBuild on your solution. On Step 3 you can choose just the tasks you want to use.

Step 1

Build the EasyBuild, put his assembly and dependencies assemblies in a folder on your solution, let me say "references\EasyBuild"

Step 2

If you don't jhave a folder to your msbuild files, just create one "msbuilds" folder on your solution root folder.

Step 3

StartWebProjectTask

Create a file called StartMyWebProject.targets on your msbuilds folder:

<Project ToolsVersion="4.0" DefaultTargets="BeforeBuild" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
    <UsingTask TaskName="StartWebProjectTask" 
        AssemblyFile="..\references\EasyBuild\EasyBuild.dll"/>
    
    	<Target Name="BeforeBuild">
    		<Message text="Starting MyWebProject..." />
    		<StartWebProjectTask projectFolderName="MyWebProject" port="8181" />
    		<Message text="MyWebProject started." />
	</Target>
</Project>

Resources2JSTask

Create a file called .Resources2JSTask.targets on your msbuilds file folder (if you don't have one, create one "msbuilds" on your solution root dir):

<Project ToolsVersion="4.0" DefaultTargets="BeforeBuild" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
    <UsingTask TaskName="Resources2JSTask" 
        AssemblyFile="..\references\EasyBuild\EasyBuild.dll"/>
    
    	<Target Name="AfterBuild">
    		<Message text="Starting Resources2JSTask..." />
    		
    		<Resources2JSTask 
    			assemblyFileName="..\<YOUR PROJECT WITH RESOURCE FILE>\bin\$(configuration)\<YOUR PROJECT WITH RESOURCE FILE>.dll" 
    			serializationFolder="..\<YOUR WEB PROJECT>Scripts\Framework\Globalization"
    			serializationFilename="<YOUR DESIRED FILE NAME>"
    			cultureCodes="pt,es,en"
    			defaultCultureCode="en" />

    		<Message text="Resources2JSTask done." />
	</Target>
</Project>

Step 4

Edit the target project file that you want use the task, and add the following line bellow the "Microsoft.CSharp.targets" one:

<Import Project="..\msbuilds\<your msbuild.targets file>" />

Step 5

Build your target project to see the task in action.

FAQ

Having troubles?

Roadmap

  • Add others tasks.
  • Publish a NuGet package.

How to improve it?

License

Licensed under the The MIT License (MIT). In others words, you can use this library for developement any kind of software: open source, commercial, proprietary and alien.