@acentera/node 0.0.33 → 0.0.35

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Binary file
Binary file
package/acentera.node CHANGED
Binary file
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@acentera/node",
3
- "version": "0.0.33",
3
+ "version": "0.0.35",
4
4
  "description": "ACenterA library",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
package/dist/index.d.ts DELETED
@@ -1,2 +0,0 @@
1
- declare const _default: any;
2
- export default _default;
package/dist/index.js DELETED
@@ -1,45 +0,0 @@
1
- "use strict";
2
- var __importDefault = (this && this.__importDefault) || function (mod) {
3
- return (mod && mod.__esModule) ? mod : { "default": mod };
4
- };
5
- Object.defineProperty(exports, "__esModule", { value: true });
6
- const os_1 = __importDefault(require("os"));
7
- const fs_1 = __importDefault(require("fs"));
8
- const path_1 = __importDefault(require("path"));
9
- function loadLibrary() {
10
- const arch = os_1.default.arch();
11
- const platform = os_1.default.platform();
12
- let libName;
13
- if (platform === 'darwin') {
14
- if (arch === 'x64') {
15
- libName = 'acentera.dylib.x86';
16
- }
17
- else {
18
- libName = 'acentera.dylib.arm64';
19
- }
20
- }
21
- else if (platform === 'linux') {
22
- if (arch === 'x64') {
23
- libName = 'acentera';
24
- }
25
- else {
26
- libName = 'acentera.arm64';
27
- }
28
- }
29
- else {
30
- throw new Error('Unsupported platform');
31
- }
32
- libName += '.node';
33
- const filePath = path_1.default.join(__dirname, libName);
34
- if (fs_1.default.existsSync(filePath)) {
35
- return require(filePath);
36
- }
37
- else {
38
- const filePathLevelUp = path_1.default.join(__dirname, '/../', libName);
39
- if (fs_1.default.existsSync(filePathLevelUp)) {
40
- return require(filePathLevelUp);
41
- }
42
- return require(libName);
43
- }
44
- }
45
- exports.default = loadLibrary();