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

chore: refactor to simplify project setup #463

Merged
merged 17 commits into from
Apr 11, 2023
Prev Previous commit
Next Next commit
docs: contributing updated
  • Loading branch information
dannyhw committed Apr 8, 2023
commit 823a2b499b6f2e9f7877a1db37808a1519959068
40 changes: 17 additions & 23 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ A good way to do that is using the example app embedded in this repository:
# Download and build this repository:
git clone https://github.com/storybookjs/react-native.git react-native-storybook
cd react-native-storybook
yarn bootstrap --core
yarn build

# make changes to try and reproduce the problem, such as adding components + stories
cd examples/expo-example
Expand Down Expand Up @@ -169,9 +169,9 @@ If you run into trouble here, make sure your node, npm, and **_yarn_** are on th
1. `cd ~` (optional)
2. `git clone https://github.com/storybookjs/react-native.git react-native-storybook` _bonus_: use your own fork for this step
3. `cd react-native-storybook`
4. `yarn bootstrap --core`
4. `yarn install`
5. `yarn build`

The command `yarn bootstrap --core` may take a long time to complete (10-20 mins) since there a lot of dependencies to install.

### Running the project

Expand Down Expand Up @@ -258,20 +258,17 @@ This sequence applies to both releases and pre-releases, but differs slightly be
```sh
# make sure you current with origin/next.
git checkout next
git pull origin next
git status

# generate changelog and edit as appropriate
# generates a Next section
yarn changelog:next x.y.z-alpha.a
# build
yarn build

# Edit the changelog/PRs as needed, then commit
git commit -m "x.y.z-alpha.a changelog"

# clean build
yarn bootstrap --reset --core
# tag release
yarn version-packages

# publish and tag the release
yarn run publish:next
yarn publish:next

# update the release page
open https://github.com/storybookjs/react-native/releases
Expand All @@ -280,22 +277,19 @@ open https://github.com/storybookjs/react-native/releases
#### Full release:

```sh
# make sure you current with origin/master.
git checkout master
# make sure you current with next.
git checkout next
git pull origin next
git status

# generate changelog and edit as appropriate
# generates a vNext section
yarn changelog x.y.z

# Edit the changelog/PRs as needed, then commit
git commit -m "x.y.z changelog"
# build
yarn build

# clean build
yarn bootstrap --reset --core
# tag release
yarn version-packages

# publish and tag the release
yarn run publish:latest
yarn publish:latest

# update the release page
open https://github.com/storybookjs/react-native/releases
Expand Down
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -35,9 +35,9 @@
"github-release": "github-release-from-changelog",
"lint": "cross-env NODE_ENV=production eslint --cache --cache-location=.cache/eslint --ext .js,.jsx,.html,.ts,.tsx,.mjs --report-unused-disable-directives",
"lint:fix": "yarn lint . --fix",
"prepareAll": "lerna run prepare",
"build": "lerna run prepare",
"version-packages": "yarn lerna version --force-publish",
"publish-alpha": "yarn lerna publish from-git --dist-tag alpha",
"publish:alpha": "yarn lerna publish from-git --dist-tag alpha",
"publish:latest": "yarn lerna publish from-git --dist-tag latest",
"publish:next": "yarn lerna publish from-git --dist-tag next",
"test": "lerna run test"
Expand Down