From 910cbe593ef7afe36caf5d4fb6f019c4c91b4d14 Mon Sep 17 00:00:00 2001 From: Kael Shipman Date: Wed, 17 Jan 2024 16:45:41 -0700 Subject: [PATCH] Included src in built package --- libs/ts-simple-db-mysql/package.json | 7 ++-- libs/ts-simple-http-client-axios/package.json | 5 ++- libs/ts-simple-http-client-rpn/package.json | 5 ++- .../package.json | 5 ++- .../ts-simple-interfaces-testing/package.json | 5 ++- libs/ts-simple-interfaces/package.json | 5 ++- libs/ts-simple-logger-console/package.json | 5 ++- libs/ts-simple-logger-winston/package.json | 5 ++- libs/ts-simple-pubsub-amqp/package.json | 5 ++- package.json | 2 +- pnpm-lock.yaml | 2 +- scripts/.internal/pkgjson.sh | 40 ++++++++++++------- 12 files changed, 56 insertions(+), 35 deletions(-) diff --git a/libs/ts-simple-db-mysql/package.json b/libs/ts-simple-db-mysql/package.json index c8632b6..e014e06 100644 --- a/libs/ts-simple-db-mysql/package.json +++ b/libs/ts-simple-db-mysql/package.json @@ -3,7 +3,7 @@ "bugs": "https://github.com/wymp/ts-simple-interfaces/issues", "dependencies": { "@wymp/ts-simple-interfaces": "workspace:^0.4.1 || ^0.5.0 || ^0.6.0 || ^0.7.0", - "mysql2": "^3.7.0" + "mysql2": "^2.0.0 || ^3.7.0" }, "description": "A Simpleā„¢-conformant wrapper around mysql", "devDependencies": { @@ -12,7 +12,8 @@ }, "files": [ "dist", - "README.md" + "README.md", + "src" ], "license": "ISC", "main": "src/index.ts", @@ -41,5 +42,5 @@ "test": "jest tests/", "typecheck": "../../scripts/typecheck.sh" }, - "version": "0.7.3" + "version": "0.7.4" } diff --git a/libs/ts-simple-http-client-axios/package.json b/libs/ts-simple-http-client-axios/package.json index 74c84e8..15ce9ed 100644 --- a/libs/ts-simple-http-client-axios/package.json +++ b/libs/ts-simple-http-client-axios/package.json @@ -11,7 +11,8 @@ }, "files": [ "dist", - "README.md" + "README.md", + "src" ], "license": "ISC", "main": "src/index.ts", @@ -40,5 +41,5 @@ "test": "jest tests/", "typecheck": "../../scripts/typecheck.sh" }, - "version": "0.7.3" + "version": "0.7.4" } diff --git a/libs/ts-simple-http-client-rpn/package.json b/libs/ts-simple-http-client-rpn/package.json index bb50ae6..d57baeb 100644 --- a/libs/ts-simple-http-client-rpn/package.json +++ b/libs/ts-simple-http-client-rpn/package.json @@ -16,7 +16,8 @@ }, "files": [ "dist", - "README.md" + "README.md", + "src" ], "license": "ISC", "main": "src/index.ts", @@ -45,5 +46,5 @@ "test": "jest tests/", "typecheck": "../../scripts/typecheck.sh" }, - "version": "0.7.3" + "version": "0.7.4" } diff --git a/libs/ts-simple-http-server-express/package.json b/libs/ts-simple-http-server-express/package.json index 2170d6d..5ea52bb 100644 --- a/libs/ts-simple-http-server-express/package.json +++ b/libs/ts-simple-http-server-express/package.json @@ -17,7 +17,8 @@ }, "files": [ "dist", - "README.md" + "README.md", + "src" ], "license": "ISC", "main": "src/index.ts", @@ -46,5 +47,5 @@ "test": "jest tests/", "typecheck": "../../scripts/typecheck.sh" }, - "version": "0.7.3" + "version": "0.7.4" } diff --git a/libs/ts-simple-interfaces-testing/package.json b/libs/ts-simple-interfaces-testing/package.json index 7df202b..d59c6ee 100644 --- a/libs/ts-simple-interfaces-testing/package.json +++ b/libs/ts-simple-interfaces-testing/package.json @@ -13,7 +13,8 @@ }, "files": [ "dist", - "README.md" + "README.md", + "src" ], "homepage": "https://github.com/kael-shipman/ts-simple-interfaces", "license": "MIT", @@ -42,5 +43,5 @@ "prettier:fix": "../../scripts/prettier-fix.sh", "typecheck": "../../scripts/typecheck.sh" }, - "version": "0.7.3" + "version": "0.7.4" } diff --git a/libs/ts-simple-interfaces/package.json b/libs/ts-simple-interfaces/package.json index c75e735..63e77c9 100644 --- a/libs/ts-simple-interfaces/package.json +++ b/libs/ts-simple-interfaces/package.json @@ -13,7 +13,8 @@ }, "files": [ "dist", - "README.md" + "README.md", + "src" ], "homepage": "https://github.com/kael-shipman/ts-simple-interfaces", "license": "MIT", @@ -42,5 +43,5 @@ "prettier:fix": "../../scripts/prettier-fix.sh", "typecheck": "../../scripts/typecheck.sh" }, - "version": "0.7.3" + "version": "0.7.4" } diff --git a/libs/ts-simple-logger-console/package.json b/libs/ts-simple-logger-console/package.json index 80e9e0c..b0cea40 100644 --- a/libs/ts-simple-logger-console/package.json +++ b/libs/ts-simple-logger-console/package.json @@ -10,7 +10,8 @@ }, "files": [ "dist", - "README.md" + "README.md", + "src" ], "license": "ISC", "main": "src/index.ts", @@ -39,5 +40,5 @@ "test": "jest tests/", "typecheck": "../../scripts/typecheck.sh" }, - "version": "0.7.3" + "version": "0.7.4" } diff --git a/libs/ts-simple-logger-winston/package.json b/libs/ts-simple-logger-winston/package.json index b97c625..40e6d16 100644 --- a/libs/ts-simple-logger-winston/package.json +++ b/libs/ts-simple-logger-winston/package.json @@ -11,7 +11,8 @@ }, "files": [ "dist", - "README.md" + "README.md", + "src" ], "license": "ISC", "main": "src/index.ts", @@ -40,5 +41,5 @@ "test": "jest tests/", "typecheck": "../../scripts/typecheck.sh" }, - "version": "0.7.3" + "version": "0.7.4" } diff --git a/libs/ts-simple-pubsub-amqp/package.json b/libs/ts-simple-pubsub-amqp/package.json index c2bcacc..913e0c7 100644 --- a/libs/ts-simple-pubsub-amqp/package.json +++ b/libs/ts-simple-pubsub-amqp/package.json @@ -16,7 +16,8 @@ }, "files": [ "dist", - "README.md" + "README.md", + "src" ], "license": "ISC", "main": "src/index.ts", @@ -45,5 +46,5 @@ "test": "jest tests/", "typecheck": "../../scripts/typecheck.sh" }, - "version": "0.7.3" + "version": "0.7.4" } diff --git a/package.json b/package.json index caaa817..242b152 100644 --- a/package.json +++ b/package.json @@ -42,5 +42,5 @@ "@types/node": "$@types/node" } }, - "version": "0.7.3" + "version": "0.7.4" } diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index b2b0d1c..219ca74 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -67,7 +67,7 @@ importers: specifier: workspace:^0.4.1 || ^0.5.0 || ^0.6.0 || ^0.7.0 version: link:../ts-simple-interfaces mysql2: - specifier: ^3.7.0 + specifier: ^2.0.0 || ^3.7.0 version: 3.7.0 devDependencies: '@types/jest': diff --git a/scripts/.internal/pkgjson.sh b/scripts/.internal/pkgjson.sh index b2d3b30..1d99393 100755 --- a/scripts/.internal/pkgjson.sh +++ b/scripts/.internal/pkgjson.sh @@ -35,11 +35,34 @@ function exit_with_error() { } function process_set_args() { - SET_KEY="$1" - SET_VAL="$2" + while [ $# -gt 0 ]; do + case "$1" in + -j|--json) + JSON="true" + shift + ;; + + -m|--merge) + JSON="true" + OPERATOR="+=" + shift + ;; + + *) + if [ -z "$SET_KEY" ]; then + SET_KEY="$1" + elif [ -z "$SET_VAL" ]; then + SET_VAL="$1" + else + exit_with_error "Unknown argument: '$1'" + fi + shift + ;; + esac + done + if [ -z "$SET_KEY" ]; then exit_with_error "No key specified"; fi if [ -z "$SET_VAL" ]; then exit_with_error "No value specified"; fi - if [ -n "$3" ]; then exit_with_error "Unknown argument: '$3'"; fi } function process_del_args() { @@ -121,17 +144,6 @@ while [ $# -gt 0 ]; do shift 2 ;; - -j|--json) - JSON="true" - shift - ;; - - -m|--merge) - JSON="true" - OPERATOR="+=" - shift - ;; - -d|--dry-run) DRY_RUN="true" shift