Skip to content

Commit

Permalink
Fix internal build script (#706)
Browse files Browse the repository at this point in the history
* fix double dist problem

* remove unused main field

* update author

* clean up pwa-kit-runtime files

* clean up pwa-kit-react-sdk files

* clean up pwa-kit-react-sdk files

* append /
  • Loading branch information
kevinxh authored Sep 1, 2022
1 parent 29377d4 commit 37ce0a3
Show file tree
Hide file tree
Showing 7 changed files with 9 additions and 20 deletions.
2 changes: 1 addition & 1 deletion packages/commerce-sdk-react/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"name": "commerce-sdk-react",
"version": "2.3.0-dev",
"description": "A library that provides react hooks for fetching data from Commerce Cloud",
"author": "dev@mobify.com",
"author": "cc-pwa-kit@salesforce.com",
"license": "See license in LICENSE",
"engines": {
"node": "^14.0.0",
Expand Down
3 changes: 1 addition & 2 deletions packages/internal-lib-build/bin/prepare-dist.js
Original file line number Diff line number Diff line change
Expand Up @@ -59,8 +59,7 @@ const main = async () => {

try {
// Get a list of files from the `npm pack --dry-run` command.
const packageFiles = await packlist()

const packageFiles = (await packlist()).filter((path) => !path.startsWith('dist/'))
// Move the required files into the `dist` folder.
await copyFiles(packageFiles, DEST_DIR)
} catch (e) {
Expand Down
2 changes: 1 addition & 1 deletion packages/internal-lib-build/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
"url": "https://github.com/SalesforceCommerceCloud/pwa-kit/issues"
},
"license": "SEE LICENSE IN LICENSE",
"author": "dev@mobify.com",
"author": "cc-pwa-kit@salesforce.com",
"bin": {
"internal-lib-build": "./bin/internal-lib-build.js"
},
Expand Down
2 changes: 1 addition & 1 deletion packages/pwa-kit-create-app/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"name": "pwa-kit-create-app",
"version": "2.3.0-dev",
"description": "Salesforce's project generator tool",
"author": "dev@mobify.com",
"author": "cc-pwa-kit@salesforce.com",
"license": "See license in LICENSE",
"repository": {
"type": "git",
Expand Down
4 changes: 1 addition & 3 deletions packages/pwa-kit-dev/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,7 @@
"url": "https://github.com/SalesforceCommerceCloud/pwa-kit/issues"
},
"license": "SEE LICENSE IN LICENSE",
"author": "[email protected]",
"main": "dist/index.js",
"author": "[email protected]",
"bin": {
"pwa-kit-dev": "bin/pwa-kit-dev.js"
},
Expand All @@ -21,7 +20,6 @@
"LICENSE",
"scripts",
"ssr",
"TERMS_OF_USE.md",
"utils",
"configs"
],
Expand Down
8 changes: 2 additions & 6 deletions packages/pwa-kit-react-sdk/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,20 +2,16 @@
"name": "pwa-kit-react-sdk",
"version": "2.3.0-dev",
"description": "A library that supports the isomorphic React rendering pipeline for Commerce Cloud Managed Runtime apps",
"main": "dist/index.js",
"engines": {
"node": "^14.0.0",
"npm": "^6.14.4 || ^7.0.0 || ^8.0.0"
},
"files": [
"bin",
"CHANGELOG.md",
"LICENSE",
"scripts",
"ssr",
"TERMS_OF_USE.md",
"utils",
"webpack"
"utils"
],
"publishConfig": {
"directory": "dist"
Expand All @@ -41,7 +37,7 @@
"bugs": {
"url": "https://github.com/SalesforceCommerceCloud/pwa-kit/issues"
},
"author": "dev@mobify.com",
"author": "cc-pwa-kit@salesforce.com",
"license": "SEE LICENSE IN LICENSE",
"dependencies": {
"@loadable/babel-plugin": "^5.13.2",
Expand Down
8 changes: 2 additions & 6 deletions packages/pwa-kit-runtime/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,16 +11,12 @@
"url": "https://github.com/SalesforceCommerceCloud/pwa-kit/issues"
},
"license": "SEE LICENSE IN LICENSE",
"author": "[email protected]",
"main": "dist/index.js",
"author": "[email protected]",
"files": [
"bin",
"LICENSE",
"scripts",
"ssr",
"TERMS_OF_USE.md",
"utils",
"webpack"
"utils"
],
"scripts": {
"format": "internal-lib-build format \"**/*.{js,jsx}\"",
Expand Down

0 comments on commit 37ce0a3

Please sign in to comment.