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

Feature: Additional template modifiers #970

Open
artman41 opened this issue Mar 17, 2023 · 1 comment
Open

Feature: Additional template modifiers #970

artman41 opened this issue Mar 17, 2023 · 1 comment

Comments

@artman41
Copy link
Contributor

Currently, we're limited to templates that will create files under either src/ or $app/src/

I think it'd be useful if templates could have a defined relative path and file extension so that we could create hrl templates & test templates.

e.g

Template

tpl_hrl_dir = include/
tpl_hrl_ext = .hrl
define tpl_hrl
-ifndef(HRL_$(n)).
-define(HRL_$(n), 1).

-endif.
endef

Execution

make new t=hrl n=my_file

include/my_file.hrl

-ifndef(HRL_my_file).
-define(HRL_my_file, 1).

-endif.
@essen
Copy link
Member

essen commented May 16, 2023

That's a good idea. Not sure about how it should be implemented but patch is welcome!

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

2 participants