Skip to content
Tomasz Janczuk edited this page May 19, 2017 · 13 revisions

This documents the release process of Edge.js based on this.

Prerequisites

Edge.js has a dependency on edge-cs. Follow the release process for edge-cs before releasing Edge.js if changes are needed.

Overall build flow

Build is done on Windows since Windows binaries for .NET Desktop are shipping as part of NPM package for Edge.js. Binaries for Mono and/or .NET Core are built at the time edge.js is installed.

0. Prerequisites

Start from a clean slate:

rmdir /s /q "%USERPROFILE%\.nuget"
git clone ...
npm i

1. Build NuGet package for Edge.js

The NuGet package enables:

  • scripting of a specific version of Node.js from .NET Desktop applications,
  • scripting of .NET Core from Node.js applications.

Update version number and description of the NuGet package in src\double\Edge.js\project.json. Then:

cd tools
build_double.bat 6.4.0

(the last is the version number of Node.js to support).

2. Run CLR->node tests

Update the SucceedsCheckingNodeVersion test in test\double\double_test\double_test.sln if the target Node.js version has changed.

Buildtest\double\double_test\double_test.sln after updating the Edge.js package with the newly built NuGet package (may need to create a local NuGet source to point the location of the built package), and re-run the tests.

3. Build Edge.js native assemblies for Windows .NET desktop

Review the list of Node.js versions to build in tools\buildall.bat. If the list changes, also create appropriate directory structure in lib\native and update version mapping in lib\edge.js.

cd tools
buildall.bat

4. Run node->CLR tests

GOTCHA Since the binaries in build now take precedence over the pre-built binaries in lib\native, in order to run tests for all node versions and flavors one must make sure build does not exist, e.g. with move build build.bak.

Update the reference to Edge.js nuget package in test\project.json.

Test Edge.js desktop and core across all node versions and x86/x64:

tetst\testall.bat

NOTE if a new Node.js version had been added in the build, update testall.bat with that version before running tests.

For good measure also test desktop and core with currently installed node version:

set EDGE_USE_CORECLR=
npm test
set EDGE_USE_CORECLR=1
npm test

4. Publish the nuget packages

To nuget.org.

5. Update the references to nuget packages in the bootstrap project

Update lib\bootstrap\project.json with NuGet package references to Edge.js and Edge.js.CSharp.

6. Build and run tests on Linux

Make sure dnvm and dotnet are up to date. Make sure you are running appropriate version of Node (e.g. with nave). Then npm i tjanczuk/edge, and run Mono and CoreCLR tests with npm test and EDGE_USE_CORECLR=1 npm test.

7. Publish Edge to NPM

Update version in package.json, update readme, tag the commit, push to Github, and publish to npm.

8. Update and publish Docker image

Update the ./Dockerfile, build, and publish. There are no rules here, every build required different babysitting so far.

9. Review Linux/Mac build scripts

Make any updates as necessary.

10. Update release notes

Add release notes on GitHub.