Skip to content

Template 'project' : Adding another backend add-on after initial build #180

Open
@ksuess

Description

@ksuess

If I add another backend add-on to a project later after the backend is build, the add-on is not installable.
This is because the Zope configuration will never be updated.
The cookiecutter-zope-instance is only applied if instance/etc/zope.ini does not exist.
See

instance/etc/zope.ini: $(BIN_FOLDER)/pip ## Create instance configuration
@echo "$(GREEN)==> Create instance configuration$(RESET)"
$(BIN_FOLDER)/pipx run cookiecutter -f --no-input --config-file instance.yaml gh:plone/cookiecutter-zope-instance
.PHONY: config
config: instance/etc/zope.ini
.PHONY: build-dev
build-dev: config ## Install Plone packages
@echo "$(GREEN)==> Setup Build$(RESET)"
$(BIN_FOLDER)/mxdev -c mx.ini
$(BIN_FOLDER)/uv pip install -r requirements-mxdev.txt
.PHONY: install
install: build-dev ## Install Plone

I suggest to run cookiecutter cookiecutter-zope-instance on every make config, not only on initial installation.
There are many possible and easy solutions to do this.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions