From 189adddc3c5fd30597391bf6c7ee48f3c6d35073 Mon Sep 17 00:00:00 2001 From: Florian Eitel Date: Mon, 15 Jun 2020 23:13:32 +0200 Subject: [PATCH 1/3] feat(awslint) Make it consumable by other projects awslint is a very helpful tool for writing CDK constructs. There are still some assumptions about the current mono-repo in the tool but nothing problematic and it can be addressed afterwards. https://github.com/aws/aws-cdk/issues/1942 --- {tools => packages}/awslint/.gitignore | 0 {tools => packages}/awslint/.npmignore | 0 {tools => packages}/awslint/LICENSE | 0 {tools => packages}/awslint/NOTICE | 0 {tools => packages}/awslint/README.md | 0 {tools => packages}/awslint/bin/awslint | 0 {tools => packages}/awslint/bin/awslint.ts | 0 {tools => packages}/awslint/lib/index.ts | 0 {tools => packages}/awslint/lib/linter.ts | 0 {tools => packages}/awslint/lib/rules/api.ts | 0 {tools => packages}/awslint/lib/rules/attributes.ts | 0 {tools => packages}/awslint/lib/rules/cfn-resource.ts | 0 {tools => packages}/awslint/lib/rules/cloudwatch-events.ts | 0 {tools => packages}/awslint/lib/rules/construct.ts | 0 {tools => packages}/awslint/lib/rules/core-types.ts | 0 {tools => packages}/awslint/lib/rules/docs.ts | 0 {tools => packages}/awslint/lib/rules/durations.ts | 0 {tools => packages}/awslint/lib/rules/exports.ts | 0 {tools => packages}/awslint/lib/rules/imports.ts | 0 {tools => packages}/awslint/lib/rules/index.ts | 0 {tools => packages}/awslint/lib/rules/integrations.ts | 0 {tools => packages}/awslint/lib/rules/module.ts | 0 {tools => packages}/awslint/lib/rules/no-unused-type.ts | 0 {tools => packages}/awslint/lib/rules/public-static-properties.ts | 0 {tools => packages}/awslint/lib/rules/resource.ts | 0 {tools => packages}/awslint/lib/rules/util.ts | 0 {tools => packages}/awslint/load.sh | 0 {tools => packages}/awslint/package.json | 0 {tools => packages}/awslint/tsconfig.json | 0 {tools => packages}/awslint/tslint.yaml | 0 30 files changed, 0 insertions(+), 0 deletions(-) rename {tools => packages}/awslint/.gitignore (100%) rename {tools => packages}/awslint/.npmignore (100%) rename {tools => packages}/awslint/LICENSE (100%) rename {tools => packages}/awslint/NOTICE (100%) rename {tools => packages}/awslint/README.md (100%) rename {tools => packages}/awslint/bin/awslint (100%) rename {tools => packages}/awslint/bin/awslint.ts (100%) rename {tools => packages}/awslint/lib/index.ts (100%) rename {tools => packages}/awslint/lib/linter.ts (100%) rename {tools => packages}/awslint/lib/rules/api.ts (100%) rename {tools => packages}/awslint/lib/rules/attributes.ts (100%) rename {tools => packages}/awslint/lib/rules/cfn-resource.ts (100%) rename {tools => packages}/awslint/lib/rules/cloudwatch-events.ts (100%) rename {tools => packages}/awslint/lib/rules/construct.ts (100%) rename {tools => packages}/awslint/lib/rules/core-types.ts (100%) rename {tools => packages}/awslint/lib/rules/docs.ts (100%) rename {tools => packages}/awslint/lib/rules/durations.ts (100%) rename {tools => packages}/awslint/lib/rules/exports.ts (100%) rename {tools => packages}/awslint/lib/rules/imports.ts (100%) rename {tools => packages}/awslint/lib/rules/index.ts (100%) rename {tools => packages}/awslint/lib/rules/integrations.ts (100%) rename {tools => packages}/awslint/lib/rules/module.ts (100%) rename {tools => packages}/awslint/lib/rules/no-unused-type.ts (100%) rename {tools => packages}/awslint/lib/rules/public-static-properties.ts (100%) rename {tools => packages}/awslint/lib/rules/resource.ts (100%) rename {tools => packages}/awslint/lib/rules/util.ts (100%) rename {tools => packages}/awslint/load.sh (100%) rename {tools => packages}/awslint/package.json (100%) rename {tools => packages}/awslint/tsconfig.json (100%) rename {tools => packages}/awslint/tslint.yaml (100%) diff --git a/tools/awslint/.gitignore b/packages/awslint/.gitignore similarity index 100% rename from tools/awslint/.gitignore rename to packages/awslint/.gitignore diff --git a/tools/awslint/.npmignore b/packages/awslint/.npmignore similarity index 100% rename from tools/awslint/.npmignore rename to packages/awslint/.npmignore diff --git a/tools/awslint/LICENSE b/packages/awslint/LICENSE similarity index 100% rename from tools/awslint/LICENSE rename to packages/awslint/LICENSE diff --git a/tools/awslint/NOTICE b/packages/awslint/NOTICE similarity index 100% rename from tools/awslint/NOTICE rename to packages/awslint/NOTICE diff --git a/tools/awslint/README.md b/packages/awslint/README.md similarity index 100% rename from tools/awslint/README.md rename to packages/awslint/README.md diff --git a/tools/awslint/bin/awslint b/packages/awslint/bin/awslint similarity index 100% rename from tools/awslint/bin/awslint rename to packages/awslint/bin/awslint diff --git a/tools/awslint/bin/awslint.ts b/packages/awslint/bin/awslint.ts similarity index 100% rename from tools/awslint/bin/awslint.ts rename to packages/awslint/bin/awslint.ts diff --git a/tools/awslint/lib/index.ts b/packages/awslint/lib/index.ts similarity index 100% rename from tools/awslint/lib/index.ts rename to packages/awslint/lib/index.ts diff --git a/tools/awslint/lib/linter.ts b/packages/awslint/lib/linter.ts similarity index 100% rename from tools/awslint/lib/linter.ts rename to packages/awslint/lib/linter.ts diff --git a/tools/awslint/lib/rules/api.ts b/packages/awslint/lib/rules/api.ts similarity index 100% rename from tools/awslint/lib/rules/api.ts rename to packages/awslint/lib/rules/api.ts diff --git a/tools/awslint/lib/rules/attributes.ts b/packages/awslint/lib/rules/attributes.ts similarity index 100% rename from tools/awslint/lib/rules/attributes.ts rename to packages/awslint/lib/rules/attributes.ts diff --git a/tools/awslint/lib/rules/cfn-resource.ts b/packages/awslint/lib/rules/cfn-resource.ts similarity index 100% rename from tools/awslint/lib/rules/cfn-resource.ts rename to packages/awslint/lib/rules/cfn-resource.ts diff --git a/tools/awslint/lib/rules/cloudwatch-events.ts b/packages/awslint/lib/rules/cloudwatch-events.ts similarity index 100% rename from tools/awslint/lib/rules/cloudwatch-events.ts rename to packages/awslint/lib/rules/cloudwatch-events.ts diff --git a/tools/awslint/lib/rules/construct.ts b/packages/awslint/lib/rules/construct.ts similarity index 100% rename from tools/awslint/lib/rules/construct.ts rename to packages/awslint/lib/rules/construct.ts diff --git a/tools/awslint/lib/rules/core-types.ts b/packages/awslint/lib/rules/core-types.ts similarity index 100% rename from tools/awslint/lib/rules/core-types.ts rename to packages/awslint/lib/rules/core-types.ts diff --git a/tools/awslint/lib/rules/docs.ts b/packages/awslint/lib/rules/docs.ts similarity index 100% rename from tools/awslint/lib/rules/docs.ts rename to packages/awslint/lib/rules/docs.ts diff --git a/tools/awslint/lib/rules/durations.ts b/packages/awslint/lib/rules/durations.ts similarity index 100% rename from tools/awslint/lib/rules/durations.ts rename to packages/awslint/lib/rules/durations.ts diff --git a/tools/awslint/lib/rules/exports.ts b/packages/awslint/lib/rules/exports.ts similarity index 100% rename from tools/awslint/lib/rules/exports.ts rename to packages/awslint/lib/rules/exports.ts diff --git a/tools/awslint/lib/rules/imports.ts b/packages/awslint/lib/rules/imports.ts similarity index 100% rename from tools/awslint/lib/rules/imports.ts rename to packages/awslint/lib/rules/imports.ts diff --git a/tools/awslint/lib/rules/index.ts b/packages/awslint/lib/rules/index.ts similarity index 100% rename from tools/awslint/lib/rules/index.ts rename to packages/awslint/lib/rules/index.ts diff --git a/tools/awslint/lib/rules/integrations.ts b/packages/awslint/lib/rules/integrations.ts similarity index 100% rename from tools/awslint/lib/rules/integrations.ts rename to packages/awslint/lib/rules/integrations.ts diff --git a/tools/awslint/lib/rules/module.ts b/packages/awslint/lib/rules/module.ts similarity index 100% rename from tools/awslint/lib/rules/module.ts rename to packages/awslint/lib/rules/module.ts diff --git a/tools/awslint/lib/rules/no-unused-type.ts b/packages/awslint/lib/rules/no-unused-type.ts similarity index 100% rename from tools/awslint/lib/rules/no-unused-type.ts rename to packages/awslint/lib/rules/no-unused-type.ts diff --git a/tools/awslint/lib/rules/public-static-properties.ts b/packages/awslint/lib/rules/public-static-properties.ts similarity index 100% rename from tools/awslint/lib/rules/public-static-properties.ts rename to packages/awslint/lib/rules/public-static-properties.ts diff --git a/tools/awslint/lib/rules/resource.ts b/packages/awslint/lib/rules/resource.ts similarity index 100% rename from tools/awslint/lib/rules/resource.ts rename to packages/awslint/lib/rules/resource.ts diff --git a/tools/awslint/lib/rules/util.ts b/packages/awslint/lib/rules/util.ts similarity index 100% rename from tools/awslint/lib/rules/util.ts rename to packages/awslint/lib/rules/util.ts diff --git a/tools/awslint/load.sh b/packages/awslint/load.sh similarity index 100% rename from tools/awslint/load.sh rename to packages/awslint/load.sh diff --git a/tools/awslint/package.json b/packages/awslint/package.json similarity index 100% rename from tools/awslint/package.json rename to packages/awslint/package.json diff --git a/tools/awslint/tsconfig.json b/packages/awslint/tsconfig.json similarity index 100% rename from tools/awslint/tsconfig.json rename to packages/awslint/tsconfig.json diff --git a/tools/awslint/tslint.yaml b/packages/awslint/tslint.yaml similarity index 100% rename from tools/awslint/tslint.yaml rename to packages/awslint/tslint.yaml From 1baba547a084f02c6155187120ee24bc0f46f8a0 Mon Sep 17 00:00:00 2001 From: Florian Eitel Date: Tue, 16 Jun 2020 22:40:15 +0200 Subject: [PATCH 2/3] fixup! feat(awslint) Make it consumable by other projects --- packages/awslint/package.json | 1 - 1 file changed, 1 deletion(-) diff --git a/packages/awslint/package.json b/packages/awslint/package.json index 959ba1f0a4697..a05295a4faf09 100644 --- a/packages/awslint/package.json +++ b/packages/awslint/package.json @@ -1,6 +1,5 @@ { "name": "awslint", - "private": true, "version": "0.0.0", "description": "Enforces the AWS Construct Library guidelines", "main": "index.js", From c1230184d5cf9e46bcba4a2d30e71c1615cc6881 Mon Sep 17 00:00:00 2001 From: Florian Eitel Date: Wed, 17 Jun 2020 01:04:58 +0200 Subject: [PATCH 3/3] fixup! fixup! feat(awslint) Make it consumable by other projects --- packages/awslint/package.json | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/packages/awslint/package.json b/packages/awslint/package.json index a05295a4faf09..46d1929aae548 100644 --- a/packages/awslint/package.json +++ b/packages/awslint/package.json @@ -8,7 +8,8 @@ "lint": "tslint -p . && pkglint", "test": "echo ok", "watch": "tsc -b -w", - "build+test+package": "npm run build+test", + "package": "mkdir -p dist/js && mv $( npm pack ) dist/js/", + "build+test+package": "npm run build+test && npm run package", "build+test": "npm run build && npm test" }, "bin": {