@electerm/ssh2 0.8.11 → 1.5.0

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.
package/README.md CHANGED
@@ -1,3 +1,10 @@
1
1
  # Description
2
2
 
3
- A fork of [Brian White](https://github.com/mscdex)'s [ssh2](https://github.com/mscdex/ssh2) for electerm.
3
+ This is a fork of [ssh2](https://github.com/mscdex/ssh2), only replace optionalDependencies with peerDependencies so ci can build successfully.
4
+
5
+ ## Use
6
+
7
+ ```bash
8
+ npm i @electerm/ssh2
9
+ ```
10
+
package/install.js ADDED
@@ -0,0 +1,20 @@
1
+ 'use strict';
2
+
3
+ const { spawnSync } = require('child_process');
4
+
5
+ // Attempt to build the bundled optional binding
6
+ const result = spawnSync('node-gyp', [
7
+ `--target=${process.version}`,
8
+ 'rebuild'
9
+ ], {
10
+ cwd: 'lib/protocol/crypto',
11
+ encoding: 'utf8',
12
+ shell: true,
13
+ stdio: 'inherit',
14
+ windowsHide: true,
15
+ });
16
+ if (result.error || result.status !== 0)
17
+ console.log('Failed to build optional crypto binding');
18
+ else
19
+ console.log('Succeeded in building optional crypto binding');
20
+ process.exit(0);