Skip to content

Commit 8c8ca4a

Browse files
committed
Improve release flow and note it
1 parent 20367e1 commit 8c8ca4a

File tree

2 files changed

+31
-4
lines changed

2 files changed

+31
-4
lines changed

HACKING.md

Lines changed: 17 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -26,19 +26,33 @@ How to execute them all
2626

2727
`make`
2828

29+
How to generate HTML phpdoc
30+
--
31+
32+
Use `make doc`
33+
34+
Pull request policy
35+
--
36+
37+
- Please *DON'T* include the generated HTML phpdoc in pull request
38+
2939
Release Flow
3040
--
3141

32-
1. Make a git tag (this project uses semantic versioning)
42+
1. Generate HTML phpdoc
43+
1. Make a git tag (this project uses [semantic versioning](http://semver.org/))
3344
1. Push the tag to origin
45+
1. Edit [GitHub releases](https://github.com/line/line-bot-sdk-php/releases)
46+
47+
You can execute steps 1-3 with `make release` command.
3448

3549
That's all. It will be publish on [composer](https://packagist.org/packages/linecorp/line-bot-sdk) automatically.
3650

3751
e.g.
3852

3953
```
40-
$ git tag 1.2.3
41-
$ git push origin 1.2.3
54+
$ make release VERSION=1.2.3
55+
# Then, edit GitHub releases
4256
```
4357

4458
Testing of HTTP client

Makefile

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
COMPOSER_BIN = ./vendor/bin
22

3-
.PHONY: default test doc phpcs phpmd check install-devtool
3+
.PHONY: default test doc phpcs phpmd check install-devtool copyright release
44

55
default: check
66

@@ -58,3 +58,16 @@ check: test copyright phpcs phpmd
5858
install-devtool:
5959
bash ./devtool/download_req_mirror.sh
6060

61+
release:
62+
ifndef VERSION
63+
@tput setaf 1
64+
@echo '[ERROR] $$VERSION is missing; it must be specified'
65+
@echo 'USAGE:'
66+
@echo ' make release VERSION=1.2.3'
67+
@tput sgr0
68+
@exit 255
69+
endif
70+
make doc
71+
git tag $(VERSION)
72+
git push origin $(VERSION)
73+

0 commit comments

Comments
 (0)