File: testpack.sh

package info (click to toggle)
node-uuid 8.3.2%2B~8.3.4-3
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 1,576 kB
  • sloc: javascript: 2,177; sh: 33; makefile: 23
file content (21 lines) | stat: -rwxr-xr-x 381 bytes parent folder | download | duplicates (5)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
#!/bin/bash -eu

# cd to the root dir
ROOT="$(pwd)/$(dirname "$0")/.."
cd "$ROOT" || exit 1

npm pack

mkdir -p ../test-pack

cp examples/node-commonjs/example.js ../test-pack/commonjs.js
cp examples/node-esmodules/example.mjs ../test-pack/esmodules.mjs

cd ../test-pack

npm init -y

npm install ../uuid/uuid-*.tgz

node commonjs.js
node --experimental-json-modules esmodules.mjs