build: package-build & release scripts should handle new pkg_npm naming (#34589)
bazel query now using: kind("ng_package|pkg_npm", //packages/...) PR Close #34589
This commit is contained in:
parent
9bb349e1c8
commit
053b23d902
|
@ -61,7 +61,7 @@ function buildTargetPackages(destPath, enableIvy, description) {
|
||||||
// all carriage return (`\r`) characters form the query output, because otherwise the carriage
|
// all carriage return (`\r`) characters form the query output, because otherwise the carriage
|
||||||
// return is part of the bazel target name and bazel will complain.
|
// return is part of the bazel target name and bazel will complain.
|
||||||
const getTargetsCmd =
|
const getTargetsCmd =
|
||||||
`${bazelCmd} query --output=label "attr('tags', '\\[.*release-with-framework.*\\]', //packages/...) intersect kind('.*_package', //packages/...)"`;
|
`${bazelCmd} query --output=label "attr('tags', '\\[.*release-with-framework.*\\]', //packages/...) intersect kind('ng_package|pkg_npm', //packages/...)"`;
|
||||||
const targets = exec(getTargetsCmd, true).split(/\r?\n/);
|
const targets = exec(getTargetsCmd, true).split(/\r?\n/);
|
||||||
|
|
||||||
// Use `--config=release` so that snapshot builds get published with embedded version info.
|
// Use `--config=release` so that snapshot builds get published with embedded version info.
|
||||||
|
|
|
@ -14,7 +14,7 @@ BAZEL_OUTPUT_BASE=$(mktemp -d -t angular-release-latest.XXXXXXX)
|
||||||
BAZEL="$BAZEL_BIN --output_base=$BAZEL_OUTPUT_BASE"
|
BAZEL="$BAZEL_BIN --output_base=$BAZEL_OUTPUT_BASE"
|
||||||
|
|
||||||
# query for all npm packages to be released as part of the framework release
|
# query for all npm packages to be released as part of the framework release
|
||||||
NPM_PACKAGE_LABELS=`${BAZEL_BIN} query --output=label 'attr("tags", "\[.*release-with-framework.*\]", //packages/...) intersect kind(".*_package", //packages/...)'`
|
NPM_PACKAGE_LABELS=`${BAZEL_BIN} query --output=label 'attr("tags", "\[.*release-with-framework.*\]", //packages/...) intersect kind("ng_package|pkg_npm", //packages/...)'`
|
||||||
# build all npm packages in parallel
|
# build all npm packages in parallel
|
||||||
$BAZEL build --config=release $NPM_PACKAGE_LABELS
|
$BAZEL build --config=release $NPM_PACKAGE_LABELS
|
||||||
# publish all packages in sequence to make it easier to spot any errors or warnings
|
# publish all packages in sequence to make it easier to spot any errors or warnings
|
||||||
|
|
|
@ -14,7 +14,7 @@ BAZEL_OUTPUT_BASE=$(mktemp -d -t angular-release-next.XXXXXXX)
|
||||||
BAZEL="$BAZEL_BIN --output_base=$BAZEL_OUTPUT_BASE"
|
BAZEL="$BAZEL_BIN --output_base=$BAZEL_OUTPUT_BASE"
|
||||||
|
|
||||||
# query for all npm packages to be released as part of the framework release
|
# query for all npm packages to be released as part of the framework release
|
||||||
NPM_PACKAGE_LABELS=`${BAZEL_BIN} query --output=label 'attr("tags", "\[.*release-with-framework.*\]", //packages/...) intersect kind(".*_package", //packages/...)'`
|
NPM_PACKAGE_LABELS=`${BAZEL_BIN} query --output=label 'attr("tags", "\[.*release-with-framework.*\]", //packages/...) intersect kind("ng_package|pkg_npm", //packages/...)'`
|
||||||
# build all npm packages in parallel
|
# build all npm packages in parallel
|
||||||
$BAZEL build --config=release $NPM_PACKAGE_LABELS
|
$BAZEL build --config=release $NPM_PACKAGE_LABELS
|
||||||
# publish all packages in sequence to make it easier to spot any errors or warnings
|
# publish all packages in sequence to make it easier to spot any errors or warnings
|
||||||
|
|
Loading…
Reference in New Issue