Skip to content

Add standalone commands#26

Open
rmccue wants to merge 18 commits into
masterfrom
init-commands
Open

Add standalone commands#26
rmccue wants to merge 18 commits into
masterfrom
init-commands

Conversation

@rmccue

@rmccue rmccue commented Mar 9, 2018

Copy link
Copy Markdown
Member

Fixes #24.

  • Converts the repo to a Lerna monorepo
  • Adds three new packages: @humanmade/create-react-wp-project, the common core of the commands; and create-react-wp-plugin and create-react-wp-theme, the user-facing commands
  • Renames react-wp-scripts.php to loader.php
  • Additionally adds either plugin.php for plugins or functions.php and style.css for themes to create a minimal plugin/theme
  • Automatically generates the PHP namespace from the last component of the path

To do:

  • Rewrite documentation for new setup
  • Testing, testing, testing
  • Switch to react-wp-scripts instead of temporary file reference

@rmccue

rmccue commented Mar 9, 2018

Copy link
Copy Markdown
Member Author

ping @kadamwhite @igmoweb @tfrommen for thoughts

@rmccue rmccue changed the title WIP: Add standalone commands Add standalone commands Mar 10, 2018
@rmccue rmccue requested review from igmoweb and kadamwhite March 10, 2018 01:44
@rmccue

rmccue commented Mar 10, 2018

Copy link
Copy Markdown
Member Author

This is ready to go, so time for review! 😁

@rmccue

rmccue commented May 15, 2018

Copy link
Copy Markdown
Member Author

@kadamwhite Ever get a chance to review this? :)

@rmccue

rmccue commented Oct 27, 2018

Copy link
Copy Markdown
Member Author

@kadamwhite Ping :D

@kadamwhite

Copy link
Copy Markdown
Collaborator

I'm unable to test this because no matter what I do with npm link, during the npx create-react-wp-plugin step the project blows up because new-plugin/node_modules/react-wp-scripts/scripts/init-extra.js is missing. If you have working steps for how to test, please advise.

Merge conflicts also need to be addressed. I know that's my fault for delaying in my review, but if you can update then I'll prioritize this.

@igmoweb

igmoweb commented Dec 5, 2018

Copy link
Copy Markdown
Contributor

@kadamwhite Would this command work?

create-react-app --scripts-version git+https://git@github.com/humanmade/react-wp-scripts.git#init-commands .

@roborourke

Copy link
Copy Markdown
Contributor

Latest CRA version allows you to specify --scripts-version file:path/to/my-scripts

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

Successfully merging this pull request may close these issues.

4 participants