Skip to content

Commit

Permalink
chore: update new release instructions
Browse files Browse the repository at this point in the history
  • Loading branch information
HZooly committed May 8, 2020
1 parent 35d9980 commit bc747ca
Showing 1 changed file with 43 additions and 15 deletions.
58 changes: 43 additions & 15 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,23 +16,10 @@ For this you have two options:
git worktree add ../vue-tour-landing landing
```

To make a new release we:
- Generate a changelog and a tagged commit by running:
```
standard-version
```
- We publish the package to npm if the CI doesn't do it for us already:
```
npm publish
```
### Pull Requests

The best practice would be to push all the changes for a new release to a `staging` branch to ensure everything is fine.
Then, when the new version is ready:
- Generate the changelog
- Merge to `master`
- Eventually run `npm publish` if not done by the CI
All pull request must target `staging`.

The landing page is built by the CI using the last sources.

### Merging PRs

Expand All @@ -42,6 +29,47 @@ git fetch origin pull/:ID/head:pr/:ID
```
Where `:ID` is the ID of the PR. The previous command will create a new branch `pr/:ID` containing the changes and commits of the PR.

### New release

Go on `staging` branch.

```
git checkout staging
```

Check result of Standard Version.

```
standard-version --dry-run
```

For a better control of the version number, use `--release-as`. <level> corresponds to semver levels: major, minor or patch.

```
standard-version --release-as <level> --dry-run
```

If result is ok, run command without `--dry-run` flag.

```
standard-version --release-as <level>
```

Push version on `staging`.

```
git push --follow-tags origin staging
```

Do a Pull Request from `staging` to `master`.

Once merged, publish on NPM from `master`.

```
git checkout master
npm publish
```

## Generating a Changelog

By using "standard" guidelines we are able to automatically generate a changelog from our git commit messages.
Expand Down

0 comments on commit bc747ca

Please sign in to comment.