Skip to content

Commit 5c6a685

Browse files
devversiontinayuangao
authored andcommitted
build: move release packages to constants (#4818)
* build: move release packages to constants * Moves the list of packages that should be released to the constants file. * Sets the executable bit flag on the `deploy-screenshot-functions.sh` script * Rename constants to build config
1 parent 2103907 commit 5c6a685

21 files changed

+28
-28
lines changed

scripts/release/deploy-screenshot-functions.sh

100644100755
File mode changed.

tools/gulp/constants.ts renamed to tools/gulp/build-config.ts

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,12 @@ export const HTML_MINIFIER_OPTIONS = {
2929
removeAttributeQuotes: false
3030
};
3131

32+
/** Packages that will be published to NPM by the release task. */
33+
export const RELEASE_PACKAGES = [
34+
'cdk',
35+
'material',
36+
];
37+
3238
export const LICENSE_BANNER = `/**
3339
* @license Angular Material v${MATERIAL_VERSION}
3440
* Copyright (c) 2017 Google, Inc. https://material.angular.io/

tools/gulp/packaging/build-bundles.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import {join} from 'path';
22
import {ScriptTarget, ModuleKind} from 'typescript';
3-
import {DIST_BUNDLES} from '../constants';
3+
import {DIST_BUNDLES} from '../build-config';
44
import {uglifyJsFile} from './minify-sources';
55
import {createRollupBundle} from './rollup-helpers';
66
import {remapSourcemap} from './sourcemap-remap';

tools/gulp/packaging/build-release.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import {join} from 'path';
2-
import {DIST_BUNDLES, DIST_ROOT, SOURCE_ROOT, PROJECT_ROOT} from '../constants';
2+
import {DIST_BUNDLES, DIST_ROOT, SOURCE_ROOT, PROJECT_ROOT} from '../build-config';
33
import {copyFiles} from '../util/copy-files';
44
import {addPureAnnotationsToFile} from './pure-annotations';
55
import {updatePackageVersion} from './package-versions';

tools/gulp/packaging/build-tasks-gulp.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import {task, watch} from 'gulp';
22
import {join} from 'path';
33
import {main as tsc} from '@angular/tsc-wrapped';
4-
import {SOURCE_ROOT, DIST_ROOT} from '../constants';
4+
import {SOURCE_ROOT, DIST_ROOT} from '../build-config';
55
import {sequenceTask, sassBuildTask, copyTask, triggerLivereload} from '../util/task_helpers';
66
import {composeRelease} from './build-release';
77
import {buildPackageBundles} from './build-bundles';

tools/gulp/packaging/package-versions.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import {writeFileSync} from 'fs';
22
import {join} from 'path';
3-
import {MATERIAL_VERSION} from '../constants';
3+
import {MATERIAL_VERSION} from '../build-config';
44

55
/** Updates the `package.json` file of the specified package. Replaces the version placeholder. */
66
export function updatePackageVersion(packageDir: string) {

tools/gulp/packaging/rollup-helpers.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import {LICENSE_BANNER} from '../constants';
1+
import {LICENSE_BANNER} from '../build-config';
22

33
// There are no type definitions available for these imports.
44
const rollup = require('rollup');

tools/gulp/packaging/typings-reexport.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import {writeFileSync} from 'fs';
2-
import {LICENSE_BANNER} from '../constants';
2+
import {LICENSE_BANNER} from '../build-config';
33
import {join} from 'path';
44

55
/** Create a typing file that links to the bundled definitions of NGC. */

tools/gulp/tasks/aot.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import {task} from 'gulp';
22
import {copySync} from 'fs-extra';
3-
import {DIST_DEMOAPP, DIST_RELEASES} from '../constants';
3+
import {DIST_DEMOAPP, DIST_RELEASES} from '../build-config';
44
import {sequenceTask, execNodeTask} from '../util/task_helpers';
55
import {join} from 'path';
66

tools/gulp/tasks/clean.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import {task} from 'gulp';
2-
import {DIST_ROOT} from '../constants';
2+
import {DIST_ROOT} from '../build-config';
33
import {cleanTask} from '../util/task_helpers';
44

55

0 commit comments

Comments
 (0)