]> git.immae.eu Git - github/wallabag/wallabag.git/blame - RELEASE_PROCESS.md
Merge pull request #3826 from wallabag/epub-toc
[github/wallabag/wallabag.git] / RELEASE_PROCESS.md
CommitLineData
923a7e8d
BD
1## Definition
2
3A release is mostly a git tag of http://github.com/wallabag/wallabag, following [semantic versioning](http://semver.org).
923a7e8d 4
6b6f7251
NL
5### Steps to release
6
a03c4d90 7During this documentation, we assume the release is `$LAST_WALLABAG_RELEASE` (like 2.3.4).
6b6f7251 8
a1272ab8 9#### Prepare the release
6b6f7251 10
a1272ab8
JB
11- Update these files with new information
12 - `app/config/wallabag.yml` (`wallabag_core.version`)
13 - `CHANGELOG.md`
14- Create a PR named "Prepare $LAST_WALLABAG_RELEASE release".
15- Wait for test to be ok, merge it.
6b6f7251 16
a1272ab8 17#### Create a new release on GitHub
6b6f7251
NL
18
19- Run these commands to create the tag:
20
7c122534
NL
21```
22git checkout master
23git pull origin master
24git checkout -b release-$LAST_WALLABAG_RELEASE
25SYMFONY_ENV=prod composer up --no-dev
45277ad2
JB
26```
27
28- Update `.travis.yml` file and replace the composer line with this one:
29
30```diff
31script:
a03c4d90
JB
32- - travis_wait bash composer install -o --no-interaction --no-progress --prefer-dist
33+ - travis_wait bash composer update -o --no-interaction --no-progress --prefer-dist
45277ad2
JB
34```
35
36- Then continue with these commands:
37
38```
39git add --force composer.lock .travis.yml
7c122534
NL
40git commit -m "Release wallabag $LAST_WALLABAG_RELEASE"
41git push origin release-$LAST_WALLABAG_RELEASE
42```
6b6f7251 43
7eff4736 44- Create a new pull request with this title `DON'T MERGE Release wallabag $LAST_WALLABAG_RELEASE`. This pull request is used to launch builds on Travis-CI.
7c122534 45- Run these command to create the package:
6b6f7251 46
7c122534 47```
a03c4d90 48make release VERSION=$LAST_WALLABAG_RELEASE
7c122534 49```
6b6f7251 50
a03c4d90
JB
51- [Create the new release on GitHub](https://github.com/wallabag/wallabag/releases/new) by targetting the `release-$LAST_WALLABAG_RELEASE` branch. You have to upload the package (generated previously).
52- Close the previously created pull request (**DO NOT MERGE IT**) and delete the `release-$LAST_WALLABAG_RELEASE` branch.
0f26c285 53- Update the URL shortener (used on `wllbg.org` to generate links like `https://wllbg.org/latest-v2-package` or `http://wllbg.org/latest-v2`)
7eff4736 54- Update Dockerfile https://github.com/wallabag/docker (and create a new tag)
a03c4d90 55- Update wallabag.org website (downloads, MD5 sum, releases and new blog post)
4fd5f670 56- Put the next patch version suffixed with `-dev` in `app/config/wallabag.yml` (`wallabag_core.version`)
7eff4736 57- Drink a :beer:!
923a7e8d
BD
58
59### `composer.lock`
60A release tag must contain a `composer.lock` file. It sets which dependencies were available at the time a release was done,
61making it easier to fix issues after the release. It also speeds up `composer install` on stable versions a LOT, by skipping the
62dependencies resolution part.
63
64Since `composer.lock` is ignored by default, either it must be removed from `.gitignore` _in the release branch_,
65or it must be added using `git add --force composer.lock`.
66
67### Target PHP version
68`composer.lock` is _always_ built for a particular version, by default the one it is generated (with `composer update`).
69
70If the PHP version used to generate the .lock isn't a widely available one (like PHP 7), a more common one should
71be locally specified in `composer.lock`:
72
73```json
74 "config": {
75 "platform": {
76 "php": "5.5.9",
77 "ext-something": "4.0"
78 }
79 }
80```