Skip to content

Commit

Permalink
Update Publish section in README
Browse files Browse the repository at this point in the history
  • Loading branch information
stefandesu committed Jun 24, 2019
1 parent dd1bef1 commit 4346159
Showing 1 changed file with 15 additions and 50 deletions.
65 changes: 15 additions & 50 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -46,63 +46,28 @@ For more information, see the [documentation].
## Publish
**For maintainers only.**

Use the following step-by-step guide to preprare and create a new Cocoda release:
Before creating a release, be aware of the following prerequisites:

1. Switch to the dev branch if necessary.
```bash
git checkout dev
```
- You are on the dev branch and your working tree is clean.
- You have the rights to push to the Cocoda repository.
- Your internet connection is working correctly.

2. Run tests and manual checks to confirm that there are no more bugs left.
If these are filfilled, you can create a release by running one of the following commands:

3. Update the version numbers in `package.json` and `package-lock.json`.

4. Commit those changes with the commit message `Release version x.y.z`.
```bash
git commit -am "Release version x.y.z"
```

5. Tag the commit with the version number.
```bash
git tag x.y.z
```

6. Push the changes including the tag.
```bash
git push --tags origin dev
```

7. Wait for the webhook to finish and check the deployed dev version [here](https://coli-conc.gbv.de/cocoda/dev/).

8. If everything looks and works like it's supposed to, change to the master branch and merge dev into master:
```bash
git checkout master
git merge dev
```
There should not be any merge conflicts and the merge should be a fast-forward merge.
9. Push the master branch.
```bash
git push
```
10. Don't forget to switch back to dev to not accidentally work on master afterwards:
```bash
git checkout dev
```

11. Either wait for the cronjob to update the deployed master branch from GitHub or trigger the update manually (if using [cocoda-services](https://github.com/gbv/cocoda-services), just type `./update.sh cocoda`). Note: If the config format changed in any way and there is a user specific config, make sure to update that config file according to the new format.

12. Check the deployed master version if everything works correctly.
```bash
# patch release, e.g. 0.8.0 -> 0.8.1
npm run release patch

13. Go to [this page](https://github.com/gbv/cocoda/tags), click on the little ellipsis next to the newest tag, and choose "Create release".
# minor release, e.g. 0.8.1 -> 0.9.0
npm run release minor

14. Let the title of the release be "Cocoda x.y.z". Write release notes according to the changes for this release, and publish the release.
# major release, e.g. 0.9.0 -> 1.0.0
npm run release major
```

15. If necessary, let social media know about the update.
After successfully creating a release, the script will show you some possible next steps.

**Note:** This process will soon be streamlined and made into a script (https://github.com/gbv/cocoda/issues/348).
If there were any errors during the release, make sure to clean up your repository before trying again (reverting the version commit, etc.).

## Contribute
We are open to pull requests, but before spending a lot of time implementing a new feature, please create an issue to discuss whether this is something we can imagine being in the main application.
Expand Down

0 comments on commit 4346159

Please sign in to comment.