From 61ae2343eaa1474f86f94a49a56aff1930f0fb5f Mon Sep 17 00:00:00 2001 From: Anton Mokhovikov Date: Thu, 8 Apr 2021 12:00:16 -0700 Subject: [PATCH 1/2] Changed Lib name and some settings. Prepare for release --- package.json | 14 +++++++------- python/rpdk/typescript/__init__.py | 2 +- python/rpdk/typescript/codegen.py | 9 +++------ setup.py | 14 +++++++------- 4 files changed, 18 insertions(+), 21 deletions(-) diff --git a/package.json b/package.json index d6ef1d0..aafb11e 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { - "name": "cfn-rpdk", - "version": "0.5.0", + "name": "cloudformation-cli-typescript-lib", + "version": "1.0.0", "description": "The CloudFormation Resource Provider Development Kit (RPDK) allows you to author your own resource providers that can be used by CloudFormation. This plugin library helps to provide runtime bindings for the execution of your providers by CloudFormation.", "private": false, "main": "dist/index.js", @@ -27,14 +27,14 @@ }, "repository": { "type": "git", - "url": "git+https://github.com/eduardomourar/cloudformation-cli-typescript-plugin.git" + "url": "git+https://github.com/aws-cloudformation/cloudformation-cli-typescript-plugin.git" }, - "author": "eduardomourar", - "license": "MIT", + "author": "Amazon Web Services", + "license": "Apache License 2.0", "bugs": { - "url": "https://github.com/eduardomourar/cloudformation-cli-typescript-plugin/issues" + "url": "https://github.com/aws-cloudformation/cloudformation-cli-typescript-plugin/issues" }, - "homepage": "https://github.com/eduardomourar/cloudformation-cli-typescript-plugin#readme", + "homepage": "https://github.com/aws-cloudformation/cloudformation-cli-typescript-plugin#readme", "dependencies": { "@org-formation/tombok": "^0.0.1", "autobind-decorator": "^2.4.0", diff --git a/python/rpdk/typescript/__init__.py b/python/rpdk/typescript/__init__.py index c3fd9ef..d708f49 100644 --- a/python/rpdk/typescript/__init__.py +++ b/python/rpdk/typescript/__init__.py @@ -1,5 +1,5 @@ import logging -__version__ = "0.5.0" +__version__ = "1.0.0" logging.getLogger(__name__).addHandler(logging.NullHandler()) diff --git a/python/rpdk/typescript/codegen.py b/python/rpdk/typescript/codegen.py index 459525d..9fe73ef 100644 --- a/python/rpdk/typescript/codegen.py +++ b/python/rpdk/typescript/codegen.py @@ -22,11 +22,9 @@ LOG = logging.getLogger(__name__) EXECUTABLE = "cfn" -SUPPORT_LIB_NAME = "cfn-rpdk" -SUPPORT_LIB_VERSION = "0.5.0" +SUPPORT_LIB_NAME = "cloudformation-cli-typescript-lib" +SUPPORT_LIB_VERSION = "^1.0.0" MAIN_HANDLER_FUNCTION = "TypeFunction" -REPO_URL = "https://github.com/eduardomourar/cloudformation-cli-typescript-plugin" -REPO_RELEASE_SUFFIX = f"v{SUPPORT_LIB_VERSION}/cfn-rpdk-{SUPPORT_LIB_VERSION}.tgz" def validate_no(value): @@ -40,7 +38,6 @@ class TypescriptLanguagePlugin(LanguagePlugin): ENTRY_POINT = "dist/handlers.entrypoint" TEST_ENTRY_POINT = "dist/handlers.testEntrypoint" CODE_URI = "./" - SUPPORT_LIB_URI = f"{REPO_URL}/releases/download/{REPO_RELEASE_SUFFIX}" def __init__(self): self.env = self._setup_jinja_env( @@ -65,7 +62,7 @@ def _init_from_project(self, project): self._use_docker = project.settings.get("useDocker", True) self.package_root = project.root / "src" self._build_command = project.settings.get("buildCommand", None) - self._lib_path = project.settings.get("supportLibrary", self.SUPPORT_LIB_URI) + self._lib_path = SUPPORT_LIB_VERSION def _init_settings(self, project): LOG.debug("Writing settings") diff --git a/setup.py b/setup.py index 8df56c2..42e9de8 100644 --- a/setup.py +++ b/setup.py @@ -28,27 +28,27 @@ def find_version(*file_paths): description=__doc__, long_description=read("README.md"), long_description_content_type="text/markdown", - author="eduardomourar", - author_email="eduardomourar@users.noreply.github.com", - url="https://github.com/eduardomourar/cloudformation-cli-typescript-plugin", + author="Amazon Web Services", + author_email="aws-cloudformation-developers@amazon.com", + url="https://github.com/aws-cloudformation/cloudformation-cli-typescript-plugin", packages=["rpdk.typescript"], package_dir={"": "python"}, # package_data -> use MANIFEST.in instead include_package_data=True, zip_safe=True, python_requires=">=3.6", - install_requires=["cloudformation-cli>=0.1.14", "zipfile38>=0.0.3,<0.2"], + install_requires=["cloudformation-cli>=0.1.14", "docker>=3.7,<5", "zipfile38>=0.0.3,<0.2"], entry_points={ "rpdk.v1.languages": [ "typescript = rpdk.typescript.codegen:TypescriptLanguagePlugin", ] }, - license="MIT", + license="Apache License 2.0", classifiers=[ - "Development Status :: 2 - Pre-Alpha", + "Development Status :: 5 - Production/Stable", "Environment :: Console", "Intended Audience :: Developers", - "License :: OSI Approved :: MIT/X Consortium License", + "License :: OSI Approved :: Apache Software License", "Natural Language :: English", "Topic :: Software Development :: Build Tools", "Topic :: Software Development :: Code Generators", From 1175bbfe470e501eb72a418888068c297a5ae0da Mon Sep 17 00:00:00 2001 From: Anton Mokhovikov Date: Thu, 8 Apr 2021 13:31:19 -0700 Subject: [PATCH 2/2] reverted codegen --- python/rpdk/typescript/__init__.py | 2 +- python/rpdk/typescript/codegen.py | 9 ++++++--- setup.py | 6 +++++- 3 files changed, 12 insertions(+), 5 deletions(-) diff --git a/python/rpdk/typescript/__init__.py b/python/rpdk/typescript/__init__.py index d708f49..c3fd9ef 100644 --- a/python/rpdk/typescript/__init__.py +++ b/python/rpdk/typescript/__init__.py @@ -1,5 +1,5 @@ import logging -__version__ = "1.0.0" +__version__ = "0.5.0" logging.getLogger(__name__).addHandler(logging.NullHandler()) diff --git a/python/rpdk/typescript/codegen.py b/python/rpdk/typescript/codegen.py index 9fe73ef..459525d 100644 --- a/python/rpdk/typescript/codegen.py +++ b/python/rpdk/typescript/codegen.py @@ -22,9 +22,11 @@ LOG = logging.getLogger(__name__) EXECUTABLE = "cfn" -SUPPORT_LIB_NAME = "cloudformation-cli-typescript-lib" -SUPPORT_LIB_VERSION = "^1.0.0" +SUPPORT_LIB_NAME = "cfn-rpdk" +SUPPORT_LIB_VERSION = "0.5.0" MAIN_HANDLER_FUNCTION = "TypeFunction" +REPO_URL = "https://github.com/eduardomourar/cloudformation-cli-typescript-plugin" +REPO_RELEASE_SUFFIX = f"v{SUPPORT_LIB_VERSION}/cfn-rpdk-{SUPPORT_LIB_VERSION}.tgz" def validate_no(value): @@ -38,6 +40,7 @@ class TypescriptLanguagePlugin(LanguagePlugin): ENTRY_POINT = "dist/handlers.entrypoint" TEST_ENTRY_POINT = "dist/handlers.testEntrypoint" CODE_URI = "./" + SUPPORT_LIB_URI = f"{REPO_URL}/releases/download/{REPO_RELEASE_SUFFIX}" def __init__(self): self.env = self._setup_jinja_env( @@ -62,7 +65,7 @@ def _init_from_project(self, project): self._use_docker = project.settings.get("useDocker", True) self.package_root = project.root / "src" self._build_command = project.settings.get("buildCommand", None) - self._lib_path = SUPPORT_LIB_VERSION + self._lib_path = project.settings.get("supportLibrary", self.SUPPORT_LIB_URI) def _init_settings(self, project): LOG.debug("Writing settings") diff --git a/setup.py b/setup.py index 42e9de8..b0e5210 100644 --- a/setup.py +++ b/setup.py @@ -37,7 +37,11 @@ def find_version(*file_paths): include_package_data=True, zip_safe=True, python_requires=">=3.6", - install_requires=["cloudformation-cli>=0.1.14", "docker>=3.7,<5", "zipfile38>=0.0.3,<0.2"], + install_requires=[ + "cloudformation-cli>=0.1.14", + "docker>=3.7,<5", + "zipfile38>=0.0.3,<0.2", + ], entry_points={ "rpdk.v1.languages": [ "typescript = rpdk.typescript.codegen:TypescriptLanguagePlugin",