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

How to contribute? #135

Open
leoj3n opened this issue Jun 9, 2016 · 9 comments
Open

How to contribute? #135

leoj3n opened this issue Jun 9, 2016 · 9 comments

Comments

@leoj3n
Copy link
Contributor

leoj3n commented Jun 9, 2016

I would have benefited from a hacking.md or Contributing section added to the README.

After grokking how generator-donejs ties into both donejs/cli and donejs/donejs, I was able finally to deduce the following steps, and see the result of my edits in generator-donejs/plugin:

  1. Clone donejs/generator-donejs.
  2. Run npm link within the cloned directory.
  3. Make a new temporary directory for testing.
  4. Run npm link generator-donejs within that new testing directory.
  5. Finally, donejs add plugin will use the linked generator, because it already exists there.

If there is a better way of setting up this project to hack on it and test generator changes, I'd like to know.

Assuming documentation does not already exist regarding how to set this up, an explanation of these steps would be very helpful for new contributors like me! Thanks 👍

@justinbmeyer
Copy link

Closing for donejs/donejs#295

@chasenlehara
Copy link
Member

Reopening this because it won’t be covered by donejs/donejs#295

@phillipskevin
Copy link
Contributor

If you just want to work on the generators specifically, you can follow the Running the Generator steps from http://yeoman.io/authoring/index.html. Perhaps we should just link to that?

@chasenlehara chasenlehara assigned rlin415 and unassigned rlin415 Feb 27, 2017
@leoj3n
Copy link
Contributor Author

leoj3n commented Mar 5, 2017

@phillipskevin The yeoman docs did help with that respective part of the initial steps. However, the yeoman docs did not help when it came to testing a modified generator in concert with other repos I had cloned locally that consume said generator (specifically, donejs/cli and donejs/donejs).

Imagine if I was updating some dependencies across all three of these repos, and I wanted to make sure everything was working nicely together without having to publish to NPM and reinstall DoneJS or something crazy like that; this is when the workflow outlined above is absolutely necessary and not documented anywhere.

For example, it's the only way that I imagine to test specific version combinations of the repos locally, and I felt it was probably most responsible to test my generator modifications within the context of the entire ecosystem like that workflow outlined in the guides.

@leoj3n
Copy link
Contributor Author

leoj3n commented Mar 5, 2017

At least, I think that's where I was going with this; it's been a while.

@leoj3n
Copy link
Contributor Author

leoj3n commented Mar 28, 2017

Related No. 1 — Using DoneJS with local copy of CLI to generate app:

donejs/cli#82 (comment)

Not sure if there's a better way of doing this without editing that file and hard-coding the path?

@leoj3n
Copy link
Contributor Author

leoj3n commented Mar 28, 2017

Related No. 2 — How To: Integrate Third Party Packages into a DoneJS Plugin:

donejs/donejs#852 (comment)

@phillipskevin
Copy link
Contributor

@leoj3n, for using a local copy of the CLI, can't you just use npm link? Maybe I'm missing something because I don't quite follow the comment you linked to.

@leoj3n
Copy link
Contributor Author

leoj3n commented Mar 28, 2017

@phillipskevin In regards to your question about "Related No. 1": Unfortunately, IIRC, that won't work because that npm command will overwrite whatever you link in; I think this is because the syntax [email protected] forces the package to come from the npm remote.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants