mirror of
https://github.com/NativeScript/NativeScript.git
synced 2025-11-05 13:26:48 +08:00
chore(build): always use local typescript
This commit is contained in:
@@ -13,6 +13,8 @@ DIST=dist;
|
||||
ROOT_DIR=$(cd `dirname $0` && pwd)/..;
|
||||
cd "$ROOT_DIR"
|
||||
|
||||
# Aways execute npx tsc from repo root to use the local typescript
|
||||
npx tsc -v
|
||||
npx tsc -p nativescript-core/tsconfig.barrels.json
|
||||
|
||||
FROM="temp/dts-out"
|
||||
|
||||
@@ -11,12 +11,15 @@ set -e
|
||||
|
||||
## Pack tns-core-modules
|
||||
(
|
||||
cd "dist/tns-core-modules"
|
||||
|
||||
echo 'Run tsc ...'
|
||||
npx tsc
|
||||
# Aways execute npx tsc from repo root to use the local typescript
|
||||
echo 'TypeScript transpile...'
|
||||
npx tsc -v
|
||||
npx tsc -p "dist/tns-core-modules"
|
||||
|
||||
|
||||
echo 'NPM packing ...'
|
||||
cd "dist/tns-core-modules"
|
||||
TGZ="$(npm pack)"
|
||||
mv "$TGZ" "../$TGZ"
|
||||
)
|
||||
@@ -65,11 +65,14 @@ mkdir -p "$DIST"
|
||||
npx ncp README.md "$DIST"/"$PACKAGE"/README.md
|
||||
|
||||
(
|
||||
echo 'TypeScript transpile...'
|
||||
cd "$DIST/$PACKAGE"
|
||||
npm install
|
||||
npx tsc
|
||||
)
|
||||
|
||||
# Aways execute npx tsc from repo root to use the local typescript
|
||||
echo 'TypeScript transpile...'
|
||||
npx tsc -v
|
||||
npx tsc -p "$DIST/$PACKAGE"
|
||||
|
||||
echo "Clearing typescript definitions from private APIs..."
|
||||
npx ts-node --project ./build/tsconfig.json build/clear-private-definitions "$DIST/$PACKAGE"
|
||||
|
||||
Reference in New Issue
Block a user