Skip to content

[Feature request] Ability to limit templates pull #87

@tyleralbee

Description

@tyleralbee

Is your feature request related to a problem? Please describe.
In cases where a single server contains templates for multiple applications, postmark templates pull can be awkward to use. This is because postmark templates pull always pulls in all of the templates within a server, and from what I understand, there is no way to specify which templates should be pulled.

This leaves the following options with regards to postmark templates pull:

  1. Use it, but add irrelevant templates to .gitignore or manually delete them before committing to version control
  2. Use it and allow the irrelevant templates to be committed to source control for an unrelated project
  3. Use it once and ensure other developers do not update templates via the Postmark GUI (to ensure synchronicity)

Of the above options, I went with 3. That said, it would be frustrating if I didn't realize someone updated the templates on remote and I overwrote them by pushing my own changes. I feel that this hampers the ability to effectively use CI/CD to manage Postmark templates, which is unfortunate.

Describe the solution you'd like
Add the ability to specify the following in a postmark config file in the root of the templates directory:

  • include: str[] - A list of template aliases
  • exclude: str[] - A list of template aliases

The file might be called postmarkrc.json or postmarkrc.js with a default export of the config object.

Describe alternatives you've considered
Alternatively, flag(s) could be added:

  • --include
  • --exclude

Additional context
For the record, I found the CLI extremely simple, powerful, and a compliment to Postmark's already top-tier service in the space. A long time ago, a developer specializing in email marketing told me not to waste my time looking for an email solution because Postmark was it. I would give that same advice today.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions