Upgrade yarn and cleanup npm commands (#10054)

* Add yarn.lock file for NodeServices
* Remove references to 'npm install' (causes double-download of node modules) and replace npm commands in package.json with yarn for consistency
* Upgrade yarn to 1.15.2
This commit is contained in:
Nate McMaster 2019-05-08 15:07:25 -07:00 committed by GitHub
parent e3bf01eec3
commit 3dbbb2994c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
13 changed files with 2997 additions and 4273 deletions

View File

@ -14,7 +14,7 @@
<PackageReference Remove="Internal.AspNetCore.Sdk" />
<PackageReference Include="NuGet.Build.Tasks" Version="5.1.0-rtm.5921" />
<PackageReference Include="Microsoft.Extensions.DependencyModel" Version="2.1.0" />
<PackageReference Include="Yarn.MSBuild" Version="1.13.0" />
<PackageReference Include="Yarn.MSBuild" Version="1.15.2" />
</ItemGroup>
<ItemGroup Condition="'$(BuildInstallers)' == 'true' AND '$(TargetOsName)' == 'win'">

View File

@ -3,7 +3,7 @@
"version": "3.0.100-preview5-011568"
},
"msbuild-sdks": {
"Yarn.MSBuild": "1.13.0",
"Yarn.MSBuild": "1.15.2",
"Microsoft.DotNet.Helix.Sdk": "2.0.0-beta.19253.2"
}
}

View File

@ -22,8 +22,8 @@
Outputs="@(WebPackOutputs)">
<RemoveDir Directories="dist" />
<Yarn Command="run build:debug" StandardOutputImportance="High" StandardErrorImportance="High" />
<Yarn Command="run build:production" StandardOutputImportance="High" StandardErrorImportance="High" />
<Yarn Command="run build:debug" />
<Yarn Command="run build:production" />
</Target>
</Project>

View File

@ -2,7 +2,7 @@
<Import Project="$([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildThisFileDirectory), Directory.Build.props))\Directory.Build.props" />
<!--
This project file is present so the CI will run `npm install` on the package.json file.
This project file is present so the CI will run `yarn install` on the package.json file.
The C# invokes node to start the tests.
-->

View File

@ -1,3 +0,0 @@
/bin/
/node_modules/
yarn.lock

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@ -37,10 +37,9 @@
<_TestSauceArgs Condition="'$(BrowserTestHostName)' != ''">$(_TestSauceArgs) --use-hostname "$(BrowserTestHostName)"</_TestSauceArgs>
</PropertyGroup>
<Message Text="test:sauce Args = $(_TestSauceArgs)" Importance="high" />
<Exec Command="npm run test:sauce -- $(_TestSauceArgs)"
<Yarn Command="run test:sauce -- $(_TestSauceArgs)"
Condition="'$(DailyTests)' == 'true'"
WorkingDirectory="$(RepositoryRoot)src/SignalR/clients/ts/FunctionalTests"
IgnoreStandardErrorWarningFormat="true" />
WorkingDirectory="$(RepositoryRoot)src/SignalR/clients/ts/FunctionalTests" />
</Target>
</Project>

View File

@ -5,8 +5,8 @@
"description": "",
"main": "index.js",
"dependencies": {
"@aspnet/signalr": "file:../signalr",
"@aspnet/signalr-protocol-msgpack": "file:../signalr-protocol-msgpack",
"@aspnet/signalr": "link:../signalr",
"@aspnet/signalr-protocol-msgpack": "link:../signalr-protocol-msgpack",
"msgpack5": "^4.0.2"
},
"devDependencies": {
@ -36,19 +36,19 @@
"ws": " ^6.0.0"
},
"scripts": {
"preclean": "cd .. && npm run build",
"preclean": "cd .. && yarn run build",
"clean": "node ../common/node_modules/rimraf/bin.js ./wwwroot/dist ./obj/js",
"prebuild": "npm run clean && npm install",
"build": "npm run build:lint && npm run build:webpack",
"prebuild": "yarn run clean && yarn install --mutex network",
"build": "yarn run build:lint && yarn run build:webpack",
"build:lint": "node ../common/node_modules/tslint/bin/tslint -c ../tslint.json -p ./tsconfig.json",
"build:webpack": "node ../common/node_modules/webpack-cli/bin/cli.js",
"pretest": "npm run build && dotnet build FunctionalTests.csproj",
"test": "tsc --noEmit && npm run test:local --",
"test:inner": "npm run build && dotnet build FunctionalTests.csproj && npm run test:local --",
"test:local": "npm run pretest && ts-node --project ./scripts/tsconfig.json ./scripts/run-tests.ts",
"test:all": "npm run pretest && ts-node --project ./scripts/tsconfig.json ./scripts/run-tests.ts --all-browsers",
"test:sauce": "npm run pretest && ts-node --project ./scripts/tsconfig.json ./scripts/run-tests.ts --sauce",
"sauce": "npm run test:sauce"
"pretest": "yarn run build && dotnet build FunctionalTests.csproj",
"test": "tsc --noEmit && yarn run test:local --",
"test:inner": "yarn run build && dotnet build FunctionalTests.csproj && yarn run test:local --",
"test:local": "yarn run pretest && ts-node --project ./scripts/tsconfig.json ./scripts/run-tests.ts",
"test:all": "yarn run pretest && ts-node --project ./scripts/tsconfig.json ./scripts/run-tests.ts --all-browsers",
"test:sauce": "yarn run pretest && ts-node --project ./scripts/tsconfig.json ./scripts/run-tests.ts --sauce",
"sauce": "yarn run test:sauce"
},
"author": "",
"license": "Apache-2.0"

View File

@ -2,17 +2,13 @@
# yarn lockfile v1
"@aspnet/signalr-protocol-msgpack@file:../signalr-protocol-msgpack":
version "3.0.0-preview4-t000"
dependencies:
msgpack5 "^4.0.2"
"@aspnet/signalr-protocol-msgpack@link:../signalr-protocol-msgpack":
version "0.0.0"
uid ""
"@aspnet/signalr@file:../signalr":
version "3.0.0-preview4-t000"
dependencies:
eventsource "^1.0.7"
request "^2.88.0"
ws "^6.0.0"
"@aspnet/signalr@link:../signalr":
version "0.0.0"
uid ""
"@types/bluebird@*":
version "3.5.23"

View File

@ -4,7 +4,7 @@
"description": "Provides a root to run npm scripts from. DO NOT PUBLISH",
"private": true,
"scripts": {
"build": "cd ./signalr && npm run build && cd ../signalr-protocol-msgpack && npm run build",
"build": "cd ./signalr && yarn run build && cd ../signalr-protocol-msgpack && yarn run build",
"pretest": "node ./common/node_modules/tslint/bin/tslint -c ./tslint.json -p ./signalr/tests/tsconfig.json && node ./common/node_modules/tslint/bin/tslint -c ./tslint.json -p ./signalr-protocol-msgpack/tests/tsconfig.json",
"test": "node ./common/node_modules/jest/bin/jest.js --config ./jest.config.js",
"coverage": "node ./common/node_modules/jest/bin/jest.js --config ./jest.config.js --coverage"

View File

@ -11,17 +11,17 @@
"test": "spec"
},
"scripts": {
"preclean": "cd ../common && npm install",
"preclean": "cd ../common && yarn install --mutex network",
"clean": "node ../common/node_modules/rimraf/bin.js ./dist",
"prebuild": "npm run clean && npm install",
"build": "npm run build:lint && npm run build:esm && npm run build:cjs && npm run build:browser && npm run build:uglify",
"prebuild": "yarn run clean && yarn install --mutex network",
"build": "yarn run build:lint && yarn run build:esm && yarn run build:cjs && yarn run build:browser && yarn run build:uglify",
"build:lint": "node ../common/node_modules/tslint/bin/tslint -c ../tslint.json -p ./tsconfig.json",
"build:esm": "node ../common/node_modules/typescript/bin/tsc --project ./tsconfig.json --module es2015 --outDir ./dist/esm -d",
"build:cjs": "node ../common/node_modules/typescript/bin/tsc --project ./tsconfig.json --module commonjs --outDir ./dist/cjs",
"build:browser": "node ../common/node_modules/webpack-cli/bin/cli.js",
"build:uglify": "node ../common/node_modules/uglify-js/bin/uglifyjs --source-map \"url='signalr-protocol-msgpack.min.js.map',content='./dist/browser/signalr-protocol-msgpack.js.map'\" --comments -o ./dist/browser/signalr-protocol-msgpack.min.js ./dist/browser/signalr-protocol-msgpack.js",
"prepack": "node ../build/embed-version.js",
"test": "echo \"Run 'npm test' in the 'clients/ts' folder to test this package\" && exit 1"
"test": "echo \"Run 'yarn test' in the 'clients/ts' folder to test this package\" && exit 1"
},
"keywords": [
"signalr",

View File

@ -11,20 +11,20 @@
"test": "spec"
},
"scripts": {
"preclean": "cd ../common && npm install",
"preclean": "cd ../common && yarn install --mutex network",
"clean": "node ../common/node_modules/rimraf/bin.js ./dist",
"prebuild": "npm run clean && npm install",
"build": "npm run build:lint && npm run build:esm && npm run build:cjs && npm run build:browser && npm run build:webworker && npm run build:uglify",
"prebuild": "yarn run clean && yarn install --mutex network",
"build": "yarn run build:lint && yarn run build:esm && yarn run build:cjs && yarn run build:browser && yarn run build:webworker && yarn run build:uglify",
"build:lint": "node ../common/node_modules/tslint/bin/tslint -c ../tslint.json -p ./tsconfig.json",
"build:esm": "node ../common/node_modules/typescript/bin/tsc --project ./tsconfig.json --module es2015 --outDir ./dist/esm -d && node ./build/process-dts.js",
"build:cjs": "node ../common/node_modules/typescript/bin/tsc --project ./tsconfig.json --module commonjs --outDir ./dist/cjs",
"build:browser": "node ../common/node_modules/webpack-cli/bin/cli.js",
"build:webworker": "node ../common/node_modules/webpack-cli/bin/cli.js --env.platform=webworker",
"build:uglify": "npm run build:uglify:browser && npm run build:uglify:webworker",
"build:uglify": "yarn run build:uglify:browser && yarn run build:uglify:webworker",
"build:uglify:browser": "node ../common/node_modules/uglify-js/bin/uglifyjs --source-map \"url='signalr.min.js.map',content='./dist/browser/signalr.js.map'\" --comments -o ./dist/browser/signalr.min.js ./dist/browser/signalr.js",
"build:uglify:webworker": "node ../common/node_modules/uglify-js/bin/uglifyjs --source-map \"url='signalr.min.js.map',content='./dist/webworker/signalr.js.map'\" --comments -o ./dist/webworker/signalr.min.js ./dist/webworker/signalr.js",
"prepack": "node ../build/embed-version.js",
"test": "echo \"Run 'npm test' in the 'clients/ts' folder to test this package\" && exit 1"
"test": "echo \"Run 'yarn test' in the 'clients/ts' folder to test this package\" && exit 1"
},
"keywords": [
"signalr",