plopjs/plop

Base path with relative path fails to find templates

オープン

#240 opened on 2020/09/19

 (5 件のコメント) (1 件のリアクション) (0 人の担当者)JavaScript (266 件のフォーク)batch import
buggood first issuehelp wanted

Repository metrics

Stars
 (6,845 個のスター)
PR merge metrics
 (PR metrics pending)

説明

Hi. I am using plop to generate a lot of boilerplate for my projects and it works great. Just encountered a scenario where,

THIS WORKS

{
                type: "addMany",
                destination: "./path/to/{{camelCase name}}",
                base: `my/templates`,
                templateFiles: "my/templates/**/*",
                stripExtensions: ["txt"],
                verbose: true,

 }

THIS DOES NOT WORK

{
                type: "addMany",
                destination: "./path/to/{{camelCase name}}",
                base: `./my/templates`,
                templateFiles: "my/templates/**/*",
                stripExtensions: ["txt"],
                verbose: true,

 }

The only difference is the prefix of ./ in the base config and plop is not able to find any files when using that. I am not sure if it is intended but thought i would let you know.

コントリビューターガイド