diff --git a/template/cookiecutter.json b/template/cookiecutter.json index 8b4ead9..3d91d41 100644 --- a/template/cookiecutter.json +++ b/template/cookiecutter.json @@ -3,7 +3,6 @@ "project_short_description": "All the boilerplate you need to create a LocalStack extension.", "project_slug": "{{ cookiecutter.project_name.lower().replace(' ', '-') }}", "module_name": "{{ cookiecutter.project_slug.replace('-', '_') }}", - "class_name": "{{ cookiecutter.project_name.replace('-', ' ').replace('_', ' ').title().replace(' ', '') }}", "full_name": "Jane Doe", "email": "jane@example.com", "github_username": "janedoe", diff --git a/template/{{cookiecutter.project_slug}}/Makefile b/template/{{cookiecutter.project_slug}}/Makefile index efd455a..c3d6a3e 100644 --- a/template/{{cookiecutter.project_slug}}/Makefile +++ b/template/{{cookiecutter.project_slug}}/Makefile @@ -20,7 +20,7 @@ install: venv $(VENV_RUN); python -m pip install -e .[dev] dist: venv - $(VENV_RUN); python -m build + $(VENV_RUN); python setup.py sdist bdist_wheel publish: clean-dist venv dist $(VENV_RUN); pip install --upgrade twine; twine upload dist/* diff --git a/template/{{cookiecutter.project_slug}}/setup.cfg b/template/{{cookiecutter.project_slug}}/setup.cfg new file mode 100644 index 0000000..17145a0 --- /dev/null +++ b/template/{{cookiecutter.project_slug}}/setup.cfg @@ -0,0 +1,22 @@ +[metadata] +name = {{ cookiecutter.project_slug }} +version = {{ cookiecutter.version }} +summary = LocalStack Extension: {{ cookiecutter.project_name }} +url = https://github.com/{{ cookiecutter.github_username }}/{{ cookiecutter.project_slug }} +author = {{ cookiecutter.full_name }} +author_email = {{ cookiecutter.email }} +description = {{ cookiecutter.project_short_description }} +long_description = file: README.md +long_description_content_type = text/markdown; charset=UTF-8 + +[options] +zip_safe = False +packages = find: + +[options.extras_require] +dev = + localstack-core>=1.0 + +[options.entry_points] +localstack.extensions = + {{ cookiecutter.project_slug }} = {{ cookiecutter.module_name }}.extension:MyExtension diff --git a/template/{{cookiecutter.project_slug}}/setup.py b/template/{{cookiecutter.project_slug}}/setup.py new file mode 100644 index 0000000..c823345 --- /dev/null +++ b/template/{{cookiecutter.project_slug}}/setup.py @@ -0,0 +1,4 @@ +#!/usr/bin/env python +from setuptools import setup + +setup() diff --git a/template/{{cookiecutter.project_slug}}/{{cookiecutter.module_name}}/extension.py b/template/{{cookiecutter.project_slug}}/{{cookiecutter.module_name}}/extension.py index 3c3671a..b833617 100644 --- a/template/{{cookiecutter.project_slug}}/{{cookiecutter.module_name}}/extension.py +++ b/template/{{cookiecutter.project_slug}}/{{cookiecutter.module_name}}/extension.py @@ -1,6 +1,6 @@ from localstack.extensions.api import Extension, http, aws -class {{ cookiecutter.class_name }}(Extension): +class MyExtension(Extension): name = "{{ cookiecutter.project_slug }}" def on_extension_load(self):