【发布时间】:2017-12-20 05:26:05
【问题描述】:
我正在编写一个生成器,其中将提示用户一个参数,我们称之为option。根据其答案,我想更改其中一个输出文件:
SomeClass.java
public class SomeClass{
//if option=x I don't want to include this attribute:
private String field1;
//if option=x I want to generate an attribute with the value of the promted attribute
private String ${info};
如何进行上述 cmets 中描述的操作?
【问题讨论】:
标签: javascript node.js yeoman yeoman-generator