Skip to content

Commit

Permalink
Merge pull request #311 from ZeroCM/core-node_upgrade
Browse files Browse the repository at this point in the history
Upgraded node to work after v10
  • Loading branch information
jbendes authored Aug 17, 2020
2 parents 9358ee0 + 0adb987 commit e0e7071
Show file tree
Hide file tree
Showing 8 changed files with 34 additions and 15 deletions.
18 changes: 18 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -54,3 +54,21 @@ jobs:
asset_path: ${{ steps.builddeb.outputs.pkgpath }}
asset_name: ${{ steps.builddeb.outputs.pkgname }}
asset_content_type: application/octet-stream
npm:
name: Npm Publish
runs-on: ubuntu-16.04
defaults:
run:
shell: bash -l {0}
steps:
- name: Checkout code
uses: actions/checkout@v2
- name: Setup node
uses: actions/setup-node@v1
with:
node-version: '12.x'
registry-url: 'https://registry.npmjs.org'
- name: Publish Npm Package
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
run: cd zcm/js/node && npm publish
1 change: 1 addition & 0 deletions docs/changelog.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,3 +6,4 @@ Improved documentation
Added can transport based on socketcan
New zcm-logplayer-gui based on gtk3
Fixed lockfiles to unlock on all program exits
Node version upgrade to support new node versions
6 changes: 3 additions & 3 deletions examples/node-client/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "zcm-example",
"version": "1.0.0",
"version": "1.0.2",
"description": "",
"scripts": {
"//": [
Expand All @@ -13,7 +13,7 @@
"dependencies": {
"big-integer": "^1.6.27",
"express": "^4.14.0",
"ref": "^1.3.3",
"zerocm": "file:/usr/local/share/node/zerocm-1.0.0.tgz"
"ref-napi": "^3.0.0",
"zerocm": "file:../../../../../../usr/local/share/node/zerocm-1.0.0.tgz"
}
}
2 changes: 1 addition & 1 deletion gen/emit/EmitNode.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ struct EmitModule : public Emitter
{
emitAutoGeneratedWarning();

emit(0, "var ref = require('ref');");
emit(0, "var ref = require('ref-napi');");
emit(0, "var bigint = require('big-integer');");
emit(0, "");
emit(0, "var UINT64_MAX = bigint('ffffffffffffffff', 16);");
Expand Down
2 changes: 1 addition & 1 deletion gen/version.h
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,6 @@

#define ZCM_MAJOR_VERSION 1
#define ZCM_MINOR_VERSION 0
#define ZCM_MICRO_VERSION 0
#define ZCM_MICRO_VERSION 2

#endif
8 changes: 4 additions & 4 deletions zcm/js/node/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,10 @@
* Could/Should be more efficent, but it should
* suffice in the short-term
******************************************************/
var ffi = require('ffi');
var ref = require('ref');
var StructType = require('ref-struct');
var ArrayType = require('ref-array');
var ffi = require('ffi-napi');
var ref = require('ref-napi');
var StructType = require('ref-struct-napi');
var ArrayType = require('ref-array-napi');
var bigint = require('big-integer');
var assert = require('assert');

Expand Down
10 changes: 5 additions & 5 deletions zcm/js/node/package.json
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
{
"name": "zerocm",
"version": "1.0.0",
"version": "1.0.2",
"description": "Bindings to Zero Communications and Marshalling",
"dependencies": {
"big-integer": "^1.6.25",
"ffi": "^2.2.0",
"ref": "^1.3.3",
"ref-array": "^1.2.0",
"ref-struct": "^1.1.0",
"ffi-napi": "^3.0.1",
"ref-array-napi": "^1.2.1",
"ref-napi": "^3.0.0",
"ref-struct-napi": "^1.1.1",
"socket.io": "^1.5.1"
}
}
2 changes: 1 addition & 1 deletion zcm/zcm.h
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ extern "C" {
*/
#define ZCM_MAJOR_VERSION 1
#define ZCM_MINOR_VERSION 0
#define ZCM_MICRO_VERSION 0
#define ZCM_MICRO_VERSION 2

#include <stdint.h>

Expand Down

0 comments on commit e0e7071

Please sign in to comment.