Skip to content

Commit 0ef8bfc

Browse files
authored
copying more files into the package (#2087)
1 parent 9d255ca commit 0ef8bfc

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

scripts/publish/build.js

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ const root = path.join(__dirname, '../..');
1414
const dist = path.join(root, 'dist');
1515
const packagesRoot = path.join(root, 'packages');
1616

17+
1718
function copy(from, to) {
1819
from = path.relative(process.cwd(), from);
1920
to = path.relative(process.cwd(), to);
@@ -105,6 +106,15 @@ Promise.resolve()
105106
return promise.then(() => current);
106107
}, Promise.resolve());
107108
})
109+
.then(() => {
110+
// Copy all resources that might have been missed.
111+
return Promise.all([
112+
'CHANGELOG.md', 'CONTRIBUTING.md', 'LICENSE', 'README.md'
113+
].map(fileName => {
114+
console.log(`Copying ${fileName}...`);
115+
return copy(fileName, path.join('dist/angular-cli', fileName));
116+
}));
117+
})
108118
.then(() => process.exit(0), (err) => {
109119
console.error(err);
110120
process.exit(1);

0 commit comments

Comments
 (0)