From 6ce14a4a69c2d11c39ff99c3c3208d7169500f21 Mon Sep 17 00:00:00 2001 From: Baptiste Chardon Date: Thu, 24 Mar 2022 00:52:28 +0100 Subject: [PATCH 1/2] build: add license and readme to built library The license, README, and CHANGELOG were missing from the built library. Added it to build step. --- package.json | 6 ++++-- projects/lib/ng-package.json | 2 +- projects/lib/package.json | 3 ++- 3 files changed, 7 insertions(+), 4 deletions(-) diff --git a/package.json b/package.json index 3c61e7e..7593c8d 100644 --- a/package.json +++ b/package.json @@ -3,13 +3,14 @@ "version": "13.0.0", "description": "State and local storage syncing for @ngrx/store", "scripts": { - "build_dist": "npm run clean && ng build lib --configuration production", + "build_dist": "npm run clean && ng build lib --configuration production && npm run copy_lib_assets", "clean": "rimraf dist", "lint": "ng lint --fix", "ng": "ng", "pretest": "npm run lint", "test": "nyc ts-node -O '{\"module\": \"commonjs\"}' node_modules/jasmine/bin/jasmine", - "prepare": "husky install" + "prepare": "husky install", + "copy_lib_assets": "copyfiles README.md CHANGELOG.md LICENSE ./dist/lib/" }, "repository": { "type": "git", @@ -59,6 +60,7 @@ "@types/node": "^14.17.0", "@typescript-eslint/eslint-plugin": "5.3.0", "@typescript-eslint/parser": "5.3.0", + "copyfiles": "^2.4.1", "crypto-js": "^4.0.0", "es6-shim": "^0.35.6", "eslint": "^8.2.0", diff --git a/projects/lib/ng-package.json b/projects/lib/ng-package.json index 4a3c57b..451b05e 100644 --- a/projects/lib/ng-package.json +++ b/projects/lib/ng-package.json @@ -7,4 +7,4 @@ "allowedNonPeerDependencies": [ "deepmerge" ] -} \ No newline at end of file +} diff --git a/projects/lib/package.json b/projects/lib/package.json index 9489dd9..46f8be1 100644 --- a/projects/lib/package.json +++ b/projects/lib/package.json @@ -9,5 +9,6 @@ "dependencies": { "deepmerge": "^4.2.2", "tslib": "^2.3.0" - } + }, + "license": "MIT" } From aa5577cd379de1064d151c4fc57acee5770c58ee Mon Sep 17 00:00:00 2001 From: Benjamin B <7598058+BBlackwo@users.noreply.github.com> Date: Wed, 30 Mar 2022 14:36:18 +1100 Subject: [PATCH 2/2] fix: move library package fields to lib package.json --- package-lock.json | 103 +++++++++++++++++++++++++++++++++++++- package.json | 23 ++------- projects/lib/package.json | 21 +++++++- 3 files changed, 123 insertions(+), 24 deletions(-) diff --git a/package-lock.json b/package-lock.json index bcafd25..8c69fd5 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,6 +1,6 @@ { - "name": "ngrx-store-localstorage", - "version": "13.0.0", + "name": "ngrx-store-localstorage-root", + "version": "0.0.0", "lockfileVersion": 1, "requires": true, "dependencies": { @@ -7292,6 +7292,63 @@ } } }, + "copyfiles": { + "version": "2.4.1", + "resolved": "https://registry.npmjs.org/copyfiles/-/copyfiles-2.4.1.tgz", + "integrity": "sha512-fereAvAvxDrQDOXybk3Qu3dPbOoKoysFMWtkY3mv5BsL8//OSZVL5DCLYqgRfY5cWirgRzlC+WSrxp6Bo3eNZg==", + "dev": true, + "requires": { + "glob": "^7.0.5", + "minimatch": "^3.0.3", + "mkdirp": "^1.0.4", + "noms": "0.0.0", + "through2": "^2.0.1", + "untildify": "^4.0.0", + "yargs": "^16.1.0" + }, + "dependencies": { + "readable-stream": { + "version": "2.3.7", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.7.tgz", + "integrity": "sha512-Ebho8K4jIbHAxnuxi7o42OrZgF/ZTNcsZj6nRKyUmkhLFq8CHItp/fy6hQZuZmP/n3yZ9VBUbp4zz/mX8hmYPw==", + "dev": true, + "requires": { + "core-util-is": "~1.0.0", + "inherits": "~2.0.3", + "isarray": "~1.0.0", + "process-nextick-args": "~2.0.0", + "safe-buffer": "~5.1.1", + "string_decoder": "~1.1.1", + "util-deprecate": "~1.0.1" + } + }, + "safe-buffer": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", + "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==", + "dev": true + }, + "string_decoder": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz", + "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==", + "dev": true, + "requires": { + "safe-buffer": "~5.1.0" + } + }, + "through2": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/through2/-/through2-2.0.5.tgz", + "integrity": "sha512-/mrRod8xqpA+IHSLyGCQ2s8SPHiCDEeQJSep1jqLYeEUClOFG2Qsh+4FU6G9VeqpZnGW/Su8LQGc4YKni5rYSQ==", + "dev": true, + "requires": { + "readable-stream": "~2.3.6", + "xtend": "~4.0.1" + } + } + } + }, "core-js": { "version": "3.19.0", "resolved": "https://registry.npmjs.org/core-js/-/core-js-3.19.0.tgz", @@ -11486,6 +11543,42 @@ "integrity": "sha512-LLUo+PpH3dU6XizX3iVoubUNheF/owjXCZZ5yACDxNnPtgFuludV1ZL3ayK1kVep42Rmm0+R9/Y60NQbZ2bifw==", "dev": true }, + "noms": { + "version": "0.0.0", + "resolved": "https://registry.npmjs.org/noms/-/noms-0.0.0.tgz", + "integrity": "sha1-2o69nzr51nYJGbJ9nNyAkqczKFk=", + "dev": true, + "requires": { + "inherits": "^2.0.1", + "readable-stream": "~1.0.31" + }, + "dependencies": { + "isarray": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/isarray/-/isarray-0.0.1.tgz", + "integrity": "sha1-ihis/Kmo9Bd+Cav8YDiTmwXR7t8=", + "dev": true + }, + "readable-stream": { + "version": "1.0.34", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-1.0.34.tgz", + "integrity": "sha1-Elgg40vIQtLyqq+v5MKRbuMsFXw=", + "dev": true, + "requires": { + "core-util-is": "~1.0.0", + "inherits": "~2.0.1", + "isarray": "0.0.1", + "string_decoder": "~0.10.x" + } + }, + "string_decoder": { + "version": "0.10.31", + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-0.10.31.tgz", + "integrity": "sha1-YuIDvEF2bGwoyfyEMB2rHFMQ+pQ=", + "dev": true + } + } + }, "nopt": { "version": "5.0.0", "resolved": "https://registry.npmjs.org/nopt/-/nopt-5.0.0.tgz", @@ -17636,6 +17729,12 @@ "integrity": "sha1-sr9O6FFKrmFltIF4KdIbLvSZBOw=", "dev": true }, + "untildify": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/untildify/-/untildify-4.0.0.tgz", + "integrity": "sha512-KK8xQ1mkzZeg9inewmFVDNkg3l5LUhoq9kN6iWYB/CC9YMG8HA+c1Q8HwDe6dEX7kErrEVNVBO3fWsVq5iDgtw==", + "dev": true + }, "uri-js": { "version": "4.4.1", "resolved": "https://registry.npmjs.org/uri-js/-/uri-js-4.4.1.tgz", diff --git a/package.json b/package.json index 7593c8d..f3edec8 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { - "name": "ngrx-store-localstorage", - "version": "13.0.0", - "description": "State and local storage syncing for @ngrx/store", + "name": "ngrx-store-localstorage-root", + "version": "0.0.0", + "private": "true", "scripts": { "build_dist": "npm run clean && ng build lib --configuration production && npm run copy_lib_assets", "clean": "rimraf dist", @@ -12,23 +12,6 @@ "prepare": "husky install", "copy_lib_assets": "copyfiles README.md CHANGELOG.md LICENSE ./dist/lib/" }, - "repository": { - "type": "git", - "url": "git@github.com:btroncone/ngrx-store-localstorage.git" - }, - "keywords": [ - "redux", - "ngrx", - "store", - "localstorage", - "rxjs" - ], - "author": "Brian Troncone", - "license": "MIT", - "bugs": { - "url": "https://github.com/btroncone/ngrx-store-localstorage/issues" - }, - "homepage": "https://github.com/btroncone/ngrx-store-localstorage#readme", "dependencies": { "@angular/animations": "~13.0.0", "@angular/common": "~13.0.0", diff --git a/projects/lib/package.json b/projects/lib/package.json index 46f8be1..beef452 100644 --- a/projects/lib/package.json +++ b/projects/lib/package.json @@ -1,6 +1,24 @@ { "name": "ngrx-store-localstorage", "version": "13.0.0", + "description": "State and local storage syncing for @ngrx/store", + "repository": { + "type": "git", + "url": "git@github.com:btroncone/ngrx-store-localstorage.git" + }, + "keywords": [ + "redux", + "ngrx", + "store", + "localstorage", + "rxjs" + ], + "author": "Brian Troncone", + "bugs": { + "url": "https://github.com/btroncone/ngrx-store-localstorage/issues" + }, + "homepage": "https://github.com/btroncone/ngrx-store-localstorage#readme", + "license": "MIT", "peerDependencies": { "@angular/common": "^13.0.0", "@angular/core": "^13.0.0", @@ -9,6 +27,5 @@ "dependencies": { "deepmerge": "^4.2.2", "tslib": "^2.3.0" - }, - "license": "MIT" + } }