|
2 | 2 |
|
3 | 3 | set -eu -o pipefail |
4 | 4 |
|
| 5 | +# Check that we're not on the main branch |
| 6 | +current_branch=$(git branch --show-current) |
| 7 | +if [ "$current_branch" = "main" ]; then |
| 8 | + echo "Error: Releases should not be done directly on the main branch." |
| 9 | + echo "Please create a release branch and run this script from there." |
| 10 | + exit 1 |
| 11 | +fi |
| 12 | + |
5 | 13 | phar='geoip2.phar' |
6 | 14 |
|
7 | 15 | changelog=$(cat CHANGELOG.md) |
@@ -46,10 +54,10 @@ perl -pi -e "s/(?<=const VERSION = ').+?(?=';)/$tag/g" src/WebService/Client.php |
46 | 54 | perl -pi -e "s{(?<=php composer\.phar require geoip2/geoip2:).+}{^$version}g" README.md |
47 | 55 |
|
48 | 56 |
|
49 | | -box_phar_hash='aa0966319f709e74bf2bf1d58ddb987903ae4f6d0a9d335ec2261813c189f7fc box.phar' |
| 57 | +box_phar_hash='f98cf885a7c07c84df66e33888f1d93f063298598e0a5f41ca322aeb9683179b box.phar' |
50 | 58 |
|
51 | 59 | if ! echo "$box_phar_hash" | sha256sum -c; then |
52 | | - wget -O box.phar "https://github.com/box-project/box/releases/download/4.6.6/box.phar" |
| 60 | + wget -O box.phar "https://github.com/box-project/box/releases/download/4.6.10/box.phar" |
53 | 61 | fi |
54 | 62 |
|
55 | 63 | echo "$box_phar_hash" | sha256sum -c |
@@ -94,10 +102,10 @@ if [ -n "$(git status --porcelain)" ]; then |
94 | 102 | fi |
95 | 103 |
|
96 | 104 | # Using Composer is possible, but they don't recommend it. |
97 | | -phpdocumentor_phar_hash='5223cc8455d53c51fcd5a3d4ac7817acdbec3f3e325981688d345f2468097230 phpDocumentor.phar' |
| 105 | +phpdocumentor_phar_hash='aa00973d88b278fe59fd8dce826d8d5419df589cb7563ac379856ec305d6b938 phpDocumentor.phar' |
98 | 106 |
|
99 | 107 | if ! echo "$phpdocumentor_phar_hash" | sha256sum -c; then |
100 | | - wget -O phpDocumentor.phar https://github.com/phpDocumentor/phpDocumentor/releases/download/v3.7.1/phpDocumentor.phar |
| 108 | + wget -O phpDocumentor.phar https://github.com/phpDocumentor/phpDocumentor/releases/download/v3.8.1/phpDocumentor.phar |
101 | 109 | fi |
102 | 110 |
|
103 | 111 | echo "$phpdocumentor_phar_hash" | sha256sum -c |
|
0 commit comments