donejs add plugin fails when run over existing project

Open
#59 0 comments 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
3/5
Estimated time
1-2 days
Newbie friendliness
35/100
Issue type
Bug
Clarity
Mostly clear
Activity status
Stale
Tech stack
javascript, node.js
Domain
cli

Research direction

Reproduce donejs add plugin in an existing project such as can-vdom and inspect the generator path shown in the error, node_modules/generator-donejs/plugin/templates/readme.md, along with the generated package.json. Trace the CLI entry point that initializes the project and confirm that the command completes without the reported template ReferenceError.

Written by the indexing model from the issue text.

Description

bug
Justins-MacBook-Pro-2:can-vdom justin$ donejs add plugin
Initializing new DoneJS application at /Users/justin/dev/can-vdom
Installing donejs-cli

> spawn-sync@1.0.15 postinstall /Users/justin/dev/can-vdom/node_modules/spawn-sync
> node postinstall

can-vdom@0.0.1 /Users/justin/dev/can-vdom
└── donejs-cli@0.9.5  extraneous

Installing generator-donejs@^0.9.0
can-vdom@0.0.1 /Users/justin/dev/can-vdom
├── donejs-cli@0.9.5  extraneous
└── generator-donejs@0.9.3  extraneous

? Project main folder .
? Application keywords donejs,canjs
? NPM version used 3
Writing package.json v0.9.5
events.js:154
      throw er; // Unhandled 'error' event
      ^

ReferenceError: /Users/justin/dev/can-vdom/node_modules/generator-donejs/plugin/templates/readme.md:3
    1| # <%= name %>
    2| 
 >> 3| [![Build Status](https://travis-ci.org/<%= githubAccount %>/<%= name %>.png?branch=master)](https://travis-ci.org/<%= githubAccount %>/<%= name %>)
    4| 
    5| <%= description %>
    6| 

Dominant language
JavaScript
Stars
6
Forks
7
PR merge metrics
No merged PRs in 30d

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from donejs/cli

All issues in donejs/cli

Similar issues

More JavaScript issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.