11load ("@npm//@angular/build-tooling/bazel/api-golden:index.bzl" , "api_golden_test_npm_package" )
22load ("@npm//@bazel/jasmine:index.bzl" , "jasmine_node_test" )
3- load ("//tools:defaults.bzl" , "pkg_npm" )
4- load ("//tools:interop.bzl" , "ts_project" )
3+ load ("//tools:defaults2.bzl" , "npm_package" , "ts_project" )
54
65# Copyright Google Inc. All Rights Reserved.
76#
@@ -11,7 +10,14 @@ package(default_visibility = ["//visibility:public"])
1110
1211licenses (["notice" ])
1312
14- # @angular-devkit/core
13+ RUNTIME_ASSETS = glob (
14+ include = ["**/*.json" ],
15+ # NB: we need to exclude the nested node_modules that is laid out by yarn workspaces
16+ exclude = [
17+ "node_modules/**" ,
18+ "src/workspace/json/test/**" ,
19+ ],
20+ )
1521
1622ts_project (
1723 name = "core" ,
@@ -21,14 +27,7 @@ ts_project(
2127 "src/**/*_spec.ts" ,
2228 ],
2329 ) + ["index.ts" ],
24- data = glob (
25- include = ["**/*.json" ],
26- # NB: we need to exclude the nested node_modules that is laid out by yarn workspaces
27- exclude = [
28- "node_modules/**" ,
29- "src/workspace/json/test/**" ,
30- ],
31- ),
30+ data = RUNTIME_ASSETS ,
3231 module_name = "@angular-devkit/core" ,
3332 deps = [
3433 "//:root_modules/@types/node" ,
@@ -73,15 +72,15 @@ genrule(
7372 cmd = "cp $(execpath //:LICENSE) $@" ,
7473)
7574
76- pkg_npm (
77- name = "npm_package " ,
75+ npm_package (
76+ name = "pkg " ,
7877 tags = ["release-package" ],
79- deps = [
78+ deps = RUNTIME_ASSETS + [
8079 ":README.md" ,
81- ":core " ,
80+ ":core_rjs " ,
8281 ":license" ,
83- "//packages/angular_devkit/core/node" ,
84- "//packages/angular_devkit/core/node/testing" ,
82+ "//packages/angular_devkit/core/node:node_rjs " ,
83+ "//packages/angular_devkit/core/node/testing:testing_rjs " ,
8584 ],
8685)
8786
0 commit comments