From 1757d7961a7f8da11ed9cc02f60680e16a728132 Mon Sep 17 00:00:00 2001 From: Jack Hadrill Date: Mon, 31 Jan 2022 00:29:14 +0000 Subject: [PATCH 1/9] Add declaration setting to tsconfig --- tsconfig.json | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tsconfig.json b/tsconfig.json index c38d8d8..ddf02ee 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -9,7 +9,8 @@ "esModuleInterop": true, /* Emit additional JavaScript to ease support for importing CommonJS modules. This enables `allowSyntheticDefaultImports` for type compatibility. */ "forceConsistentCasingInFileNames": true, /* Ensure that casing is correct in imports. */ "strict": true, /* Enable all strict type-checking options. */ - "skipLibCheck": true /* Skip type checking all .d.ts files. */ + "skipLibCheck": true, /* Skip type checking all .d.ts files. */ + "declaration": true }, "exclude": ["tests"] } -- 2.40.1 From b4858a84d95682e0690dd3308ed3eeea26dea447 Mon Sep 17 00:00:00 2001 From: Jack Hadrill Date: Mon, 31 Jan 2022 00:35:30 +0000 Subject: [PATCH 2/9] Add typings location --- package.json | 1 + 1 file changed, 1 insertion(+) diff --git a/package.json b/package.json index 64f0a60..c6280b1 100644 --- a/package.json +++ b/package.json @@ -3,6 +3,7 @@ "version": "1.0.0", "description": "An implementation of the Romulus-M cryptography specification.", "main": "index.js", + "typings": "./dist/index.d.ts", "scripts": { "lint": "ts-standard", "test": "jest", -- 2.40.1 From 8fe7072b831f8f6c48628bc7c2a3490dfd8f73b9 Mon Sep 17 00:00:00 2001 From: Jack Hadrill Date: Mon, 31 Jan 2022 00:37:57 +0000 Subject: [PATCH 3/9] Update main location --- package.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/package.json b/package.json index c6280b1..c50d3cc 100644 --- a/package.json +++ b/package.json @@ -2,8 +2,8 @@ "name": "romulus-js", "version": "1.0.0", "description": "An implementation of the Romulus-M cryptography specification.", - "main": "index.js", - "typings": "./dist/index.d.ts", + "main": "./dist/index.js", + "types": "./dist/index.d.ts", "scripts": { "lint": "ts-standard", "test": "jest", -- 2.40.1 From d534332ec9c8cbf37da96bc75e7dc0cda27806d5 Mon Sep 17 00:00:00 2001 From: Jack Hadrill Date: Mon, 31 Jan 2022 00:50:42 +0000 Subject: [PATCH 4/9] Add prepare script --- package.json | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/package.json b/package.json index c50d3cc..205b98e 100644 --- a/package.json +++ b/package.json @@ -7,7 +7,8 @@ "scripts": { "lint": "ts-standard", "test": "jest", - "build": "tsc" + "build": "tsc", + "prepare": "tsc" }, "repository": { "type": "git", -- 2.40.1 From 3347c49fa29663706a8fa3a537f87d3750df6341 Mon Sep 17 00:00:00 2001 From: Jack Hadrill Date: Mon, 31 Jan 2022 00:53:10 +0000 Subject: [PATCH 5/9] Exclude dist from compiler input --- tsconfig.json | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/tsconfig.json b/tsconfig.json index ddf02ee..aabd87d 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -12,5 +12,8 @@ "skipLibCheck": true, /* Skip type checking all .d.ts files. */ "declaration": true }, - "exclude": ["tests"] + "exclude": [ + "./tests/**/*", + "./dist/**/*" + ] } -- 2.40.1 From 360f272323e720fb79105afe9ae1f104ba8d19d7 Mon Sep 17 00:00:00 2001 From: Jack Hadrill Date: Mon, 31 Jan 2022 00:56:04 +0000 Subject: [PATCH 6/9] Update typings and build excludes --- package.json | 4 ++-- tsconfig.json | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/package.json b/package.json index 205b98e..e2664f0 100644 --- a/package.json +++ b/package.json @@ -2,8 +2,8 @@ "name": "romulus-js", "version": "1.0.0", "description": "An implementation of the Romulus-M cryptography specification.", - "main": "./dist/index.js", - "types": "./dist/index.d.ts", + "main": "index.js", + "types": "index", "scripts": { "lint": "ts-standard", "test": "jest", diff --git a/tsconfig.json b/tsconfig.json index aabd87d..f48a496 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -13,7 +13,7 @@ "declaration": true }, "exclude": [ - "./tests/**/*", - "./dist/**/*" + "tests", + "dist" ] } -- 2.40.1 From d1769651aa17cf64053cbdd517e60df0a65c2fc4 Mon Sep 17 00:00:00 2001 From: Jack Hadrill Date: Mon, 31 Jan 2022 00:57:33 +0000 Subject: [PATCH 7/9] Add prepack script --- package.json | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/package.json b/package.json index e2664f0..42202f9 100644 --- a/package.json +++ b/package.json @@ -8,7 +8,8 @@ "lint": "ts-standard", "test": "jest", "build": "tsc", - "prepare": "tsc" + "prepare": "tsc", + "prepack": "tsc" }, "repository": { "type": "git", -- 2.40.1 From e6568a8b00cd9b96380d8b1fa8df78fb0377a99e Mon Sep 17 00:00:00 2001 From: Jack Hadrill Date: Mon, 31 Jan 2022 01:02:04 +0000 Subject: [PATCH 8/9] Add postinstall --- package.json | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/package.json b/package.json index 42202f9..ca67c34 100644 --- a/package.json +++ b/package.json @@ -8,8 +8,7 @@ "lint": "ts-standard", "test": "jest", "build": "tsc", - "prepare": "tsc", - "prepack": "tsc" + "postinstall": "tsc" }, "repository": { "type": "git", -- 2.40.1 From 338cb017f2df428cd9f77f5211b9e5bb5bc1a161 Mon Sep 17 00:00:00 2001 From: Jack Hadrill Date: Mon, 31 Jan 2022 01:03:18 +0000 Subject: [PATCH 9/9] Update main and types --- package.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/package.json b/package.json index ca67c34..797a9ed 100644 --- a/package.json +++ b/package.json @@ -2,8 +2,8 @@ "name": "romulus-js", "version": "1.0.0", "description": "An implementation of the Romulus-M cryptography specification.", - "main": "index.js", - "types": "index", + "main": "dist/index.js", + "types": "dist/index.d.ts", "scripts": { "lint": "ts-standard", "test": "jest", -- 2.40.1