-
Notifications
You must be signed in to change notification settings - Fork 185
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
5 changed files
with
66 additions
and
67 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
#!/usr/bin/env bash | ||
|
||
# | ||
# This utility can help with rebuilding the native node-pty modules on | ||
# a given platform. On Linux and Mac, it should produce a file | ||
# /tmp/pty.node | ||
# | ||
# Parameters: | ||
# $1: [optional] major version of Electron to target default=11 | ||
# | ||
|
||
set -e | ||
set -o pipefail | ||
|
||
# temporary directory | ||
T=$(mktemp -d) | ||
|
||
cd "$T" | ||
npm init -y | ||
npm install node-pty@0.10.1 | ||
cd node_modules/node-pty | ||
|
||
cat <<EOF > .npmrc | ||
runtime=electron | ||
target=${1-11}.0.0 | ||
build_from_source=true | ||
disturl=https://atom.io/download/electron | ||
EOF | ||
|
||
echo "Building pty.node in $(pwd)" | ||
echo "Using this npmrc" | ||
cat .npmrc | ||
|
||
npm run install | ||
cp build/Release/pty.node /tmp | ||
ls -l /tmp/pty.node | ||
|
||
echo "Successfully built /tmp/pty.node" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file added
BIN
+9.71 KB
packages/builder/dist/electron/vendor/node-pty/build/darwin-arm64/electron/pty.node.gz
Binary file not shown.