Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Output target name deprecation #168

Open
jayvdb opened this issue Jan 16, 2019 · 0 comments
Open

Output target name deprecation #168

jayvdb opened this issue Jan 16, 2019 · 0 comments
Milestone

Comments

@jayvdb
Copy link
Member

jayvdb commented Jan 16, 2019

Extending on #167, in addition to handling renames, it would be very nice to allow managed deprecation of target names. e.g.

targets:
  - output: foo
    template: bar/foo.jj2
    deprecated_output_names: bar  # will be used if present, with warning
    removed_output_names: baz  # will be deleted if present

The other half of this would be foo.jj2

{% if __target__ == 'foo' %}
// emit new format
{% else %}
// emit old format
{% endif %}

e.g. this could be used to manage the transition from .eslint.json to .eslint.yaml, allowing managed repos to not immediately switch formats, which may be necessary because they find bugs in the new template, or that the generated output file has a negative effect.

@jayvdb jayvdb added this to the 0.6.0 milestone Jan 24, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant