Skip to content

Commit d526de3

Browse files
Add NPM to release process
1 parent cf09b5b commit d526de3

File tree

4 files changed

+15
-5
lines changed

4 files changed

+15
-5
lines changed

package.json

-1
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,6 @@
8282
"bugs": {
8383
"url": "https://github.com/salesforce/design-system-react/issues"
8484
},
85-
"jsnext:main": "components/index.js",
8685
"main": "components/index.js",
8786
"module": "components/index.js",
8887
"homepage": "https://react.lightningdesignsystem.com",

scripts/dist.sh

-1
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,6 @@ echo "## Cloning additional files"
2929

3030
cp .gitignore .tmp/.gitignore
3131
cp LICENSE.txt .tmp/LICENSE.txt
32-
cp CONTRIBUTING.md .tmp/CONTRIBUTING.md
3332
cp package.json .tmp/package.json
3433
cp docs/README-dist.md .tmp/README.md
3534

scripts/publish-to-git.js

+3-3
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,6 @@
33

44
/* eslint-disable no-console, global-require */
55

6-
console.log('# Publishing to git');
7-
86
import async from 'async';
97
import fs from 'fs';
108
import path from 'path';
@@ -13,6 +11,8 @@ import minimist from 'minimist';
1311
import { version } from '../package.json';
1412
import exec from './command-line-utilities';
1513

14+
console.log('# Publishing to git');
15+
1616
const argv = minimist(process.argv.slice(2));
1717
const rootPath = path.resolve(__dirname, '../');
1818
const getTmpPath = (type) =>
@@ -103,7 +103,7 @@ const publish = (done, type) => {
103103
async.eachSeries(actions, exec, (err) => {
104104
if (err) throw err;
105105

106-
// console.log(`## Successfully published ${type} to git`);
106+
console.log(`## Successfully published ${type} to git`);
107107

108108
done();
109109
});

scripts/release.js

+12
Original file line numberDiff line numberDiff line change
@@ -106,6 +106,18 @@ const tasks = ({ release, done }) => {
106106
{
107107
message: `# Pushing local master branch to ${remote} remote`,
108108
command: `git push ${remote} master --no-verify`
109+
},
110+
{
111+
message: '# Set up NPM configuration',
112+
command: 'cp scripts/.npmrc .npmrc'
113+
},
114+
{
115+
message: '# Publish to NPM',
116+
command: 'npm publish .tmp-npm'
117+
},
118+
{
119+
message: '# Remove NPM configuration',
120+
command: 'rm .npmrc'
109121
}
110122
]
111123
.filter((item) => !item.ignoreCommand)

0 commit comments

Comments
 (0)