First of all, I'd like to welcome you for thinking about contributing to this project. I'd rather explain the flow of this project and explain all that in a later release.
- Git Clone
git clone https://github.com/ahmadawais/create-guten-block/ yarnyarn create-guten-block demo-blockyarn updated
git clone https://github.com/ahmadawais/create-guten-block/yarnorsudo yarn- Installs all the node packages and deps/devDeps in all the workspaces.
yarn create-guten-block demo-block- This will run
tasks/cgb.jsfile - Which will run
./packages/create-guten-block/index.js - And your new block plugin called
demo-blockgets added at the root of this project (which you should delete after testing).
- This will run
- Now go to
cd demo-block - Run
npm startoryarn start - This will compile your code in
distand you're good to go. - Run
yarn updatedto check which npm packages were updated - Finally publish with 'yarn publishNPM' since yarn has some issues with publishing with lerna not sure why.
- Check caveats for publishing.
- Some issue with yarn not being able to publish via lerna
- Use yarn with everything else but lerna
- To publish always run via
npmthis commandnpm run lerna(Only for maintainers)
- Use
// @remove-file-on-ejectto do just that. - Use
// @remove-on-eject-beginto do just that. - Use
// @remove-on-eject-endto do just that.
What is that? I like emoji and I have invented a way to keep the git log clean and simple. Read this Emoji-log to learn more.
There's a new workflow for core developers of create-guten-block.
- Git Clone
git clone https://github.com/ahmadawais/create-guten-block/ - You need to have both
yarnandnpmthen runyarnin the root ofcreate-guten-blockfolder - You also need publishing access to all the
npmpackages in CGB so ask for that from @AhmadAwais - Now create your branch
git checkout -b githubname/feaureand commit all changes in it - Then publish all changes as
canarychanges which are not distrubted to production sites and are meant for testing while developingnpmpackages. - To publish canary package run
npm run releaseCanarytypeyto confirm - Now you can test changes by using
-cor--canaryflagnpx create-guten-block blockName -c - I recommend that you run the latest
create-guten-blockCLI if you changed anything there. You can do that by installing the latestcreate-guten-blockthat you published as canary e.g.npx create-guten-block@1.12.0-alpha.148a0211 -c blockName