2525 - name : Install tools and dependencies
2626 run : |
2727 sudo apt-get update
28- sudo apt-get install make autoconf automake libtool libtool-bin m4 wget libc-bin gzip bzip2 bison g++ git re2c
28+ sudo apt-get install make autoconf automake libtool libtool-bin m4 curl libc-bin gzip bzip2 bison g++ git re2c ca-certificates
2929
3030 - name : Prepare compile.sh download cache
3131 id : download-cache
@@ -44,16 +44,19 @@ jobs:
4444
4545 - name : Create tarball
4646 run : |
47- tar -czf ./PHP-Linux-x86_64-PM${{ matrix.pm-version-major }}.tar.gz bin
48- tar -czf ./PHP-Linux-x86_64-PM${{ matrix.pm-version-major }}-debugging-symbols.tar.gz bin-debug
47+ tar -czf ./PHP-Linux-x86_64.tar.gz bin
48+ tar -czf ./PHP-Linux-x86_64-debugging-symbols.tar.gz bin-debug
49+ cp ./PHP-Linux-x86_64.tar.gz ./PHP_Linux-x86_64.tar.gz
50+ zip -r ./Linux.zip ./PHP_Linux-x86_64.tar.gz
4951
5052 - name : Upload artifacts
5153 uses : actions/upload-artifact@v4
5254 if : always()
5355 with :
5456 name : Linux-PM${{ matrix.pm-version-major }}
5557 path : |
56- ./PHP-Linux-x86_64-PM${{ matrix.pm-version-major }}*.tar.gz
58+ ./Linux.zip
59+ ./PHP-Linux-x86_64*.tar.gz
5760 install.log
5861 compile.sh
5962 if-no-files-found : error
@@ -80,10 +83,10 @@ jobs:
8083
8184 steps :
8285 - uses : actions/checkout@v4
83-
86+
8487 - name : Install tools and dependencies
8588 run : brew install libtool autoconf automake pkg-config bison re2c
86-
89+
8790 - name : Prepare compile.sh download cache
8891 id : download-cache
8992 uses : actions/cache@v3
@@ -98,19 +101,19 @@ jobs:
98101 set -ex
99102 trap "exit 1" ERR
100103 ./compile.sh -t mac-x86-64 -j4 -g -P ${{ matrix.pm-version-major }} -c ./download_cache -D
101-
104+
102105 - name : Create tarball
103106 run : |
104- tar -czf ./PHP-MacOS-x86_64-PM${{ matrix.pm-version-major }} .tar.gz bin
105- tar -czf ./PHP-MacOS-x86_64-PM${{ matrix.pm-version-major }}- debugging-symbols.tar.gz bin-debug
106-
107+ tar -czf ./PHP-MacOS-x86_64.tar.gz bin
108+ tar -czf ./PHP-MacOS-x86_64-debugging-symbols.tar.gz bin-debug
109+
107110 - name : Upload artifacts
108111 uses : actions/upload-artifact@v4
109112 if : always()
110113 with :
111114 name : MacOS-PM${{ matrix.pm-version-major }}
112115 path : |
113- ./PHP-MacOS-x86_64-PM${{ matrix.pm-version-major }} *.tar.gz
116+ ./PHP-MacOS-x86_64*.tar.gz
114117 install.log
115118 compile.sh
116119 if-no-files-found : error
@@ -137,10 +140,10 @@ jobs:
137140
138141 steps :
139142 - uses : actions/checkout@v4
140-
143+
141144 - name : Install tools and dependencies
142145 run : choco install wget --no-progress
143-
146+
144147 - name : Compile PHP
145148 run : .\windows-compile-vs.bat
146149 env :
@@ -151,8 +154,8 @@ jobs:
151154 - name : Rename artifacts
152155 run : |
153156 mkdir temp
154- move php-debug-pack-*.zip temp/PHP-Windows-x64-PM${{ matrix.pm-version-major }}- debugging-symbols.zip
155- move php-*.zip temp/PHP-Windows-x64-PM${{ matrix.pm-version-major }} .zip
157+ move php-debug-pack-*.zip temp/PHP-Windows-x64-debugging-symbols.zip
158+ move php-*.zip temp/PHP-Windows-x64.zip
156159 move temp\*.zip .
157160
158161 - name : Upload artifacts
@@ -174,71 +177,50 @@ jobs:
174177
175178 steps :
176179 - uses : actions/checkout@v4
177-
180+
178181 - name : Set version information
179182 id : version
180183 run : |
181184 echo PHP_VERSION=$(echo ${{ github.ref_name }} | cut -d / -f2) >> $GITHUB_OUTPUT
182-
185+
183186 - name : Update latest tag target
184187 run : |
185- git tag -f php-${{ steps.version.outputs.PHP_VERSION }}-latest
186- git push -f origin php-${{ steps.version.outputs.PHP_VERSION }}-latest
188+ git tag -f ${{ steps.version.outputs.PHP_VERSION }}
189+ git push -f origin ${{ steps.version.outputs.PHP_VERSION }}
190+ git tag -f ${{ steps.version.outputs.PHP_VERSION }}-pm5
191+ git push -f origin ${{ steps.version.outputs.PHP_VERSION }}-pm5
187192
188193 - name : Download artifacts
189194 uses : actions/download-artifact@v4
190195 with :
191196 path : ${{ github.workspace }}
192197
193- - name : Generate release notes
194- run : |
195- echo "Last updated on **$(date -u +'%Y-%m-%d at %H:%M:%S %Z')**" > changelog.md
196- echo -e "\n\n" >> changelog.md
197- echo "Built by: ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}" >> changelog.md
198- if [[ "${{ github.ref_name }}" != "${{ github.event.repository.default_branch }}" ]]; then
199- echo -e "\n\n\n" >> changelog.md
200- if [[ "${{ github.ref_name }}" == *"preview" ]]; then
201- echo "# :warning: :radioactive: EXPERIMENTAL!!! :radioactive: :warning:" >> changelog.md
202- echo "### Your server and/or plugins may crash or misbehave with this release!" >> changelog.md
203- echo "### Consider downloading the [recommended release](${{ github.server_url }}/${{ github.repository }}/releases/latest) instead." >> changelog.md
204- else
205- echo ":warning: WARNING! :warning:" >> changelog.md
206- echo "Some plugins might not work properly on this version yet." >> changelog.md
207- echo "If you have problems, try the [recommended release](${{ github.server_url }}/${{ github.repository }}/releases/latest) instead." >> changelog.md
208- fi
209- else
210- echo ":white_check_mark: This version is recommended for production servers." >> changelog.md
211- fi
212- echo -e "\n\n\n" >> changelog.md
213- echo ":information_source: **Linux/MacOS users**: Please see [this page](https://doc.pmmp.io/en/rtfd/faq/installation/opcache.so.html) to fix extension loading errors. Also, check out the [PocketMine-MP Linux/MacOS installer](https://doc.pmmp.io/en/rtfd/installation/get-dot-pmmp-dot-io.html)." >> changelog.md
214-
215198 - name : Update latest branch release
216199217200 with :
218201 artifacts : |
219- ${{ github.workspace }}/Linux-PM*/*.tar.gz
220- ${{ github.workspace }}/MacOS-PM*/ *.tar.gz
221- ${{ github.workspace }}/Windows-PM*/ *.zip
202+ ${{ github.workspace }}/Linux-PM4/Linux.zip
203+ ${{ github.workspace }}/MacOS-PM4/PHP- *.tar.gz
204+ ${{ github.workspace }}/Windows-PM4/PHP- *.zip
222205 makeLatest : ${{ github.ref_name == github.event.repository.default_branch }}
223- name : PHP ${{ steps.version.outputs.PHP_VERSION }} - Latest (Build ${{ github.run_number }})
224- tag : php- ${{ steps.version.outputs.PHP_VERSION }}-latest
206+ name : PHP ${{ steps.version.outputs.PHP_VERSION }} for PM4
207+ tag : ${{ steps.version.outputs.PHP_VERSION }}
225208 commit : ${{ github.sha }}
226209 allowUpdates : true
227- bodyFile : ${{ github.workspace }}/changelog.md
228210 removeArtifacts : true
229211 prerelease : ${{ endsWith(github.ref_name, '-preview') }}
230212
231- - name : Publish unique release
213+ - name : Update latest branch release
232214233215 with :
234216 artifacts : |
235- ${{ github.workspace }}/Linux-PM*/*.tar.gz
236- ${{ github.workspace }}/MacOS-PM*/ *.tar.gz
237- ${{ github.workspace }}/Windows-PM*/ *.zip
238- makeLatest : false
239- name : PHP ${{ steps.version.outputs.PHP_VERSION }} (Build ${{ github.run_number }})
240- tag : php- ${{ steps.version.outputs.PHP_VERSION }}-build-${{ github.run_number }}
217+ ${{ github.workspace }}/Linux-PM5/Linux.zip
218+ ${{ github.workspace }}/MacOS-PM5/PHP- *.tar.gz
219+ ${{ github.workspace }}/Windows-PM5/PHP- *.zip
220+ makeLatest : ${{ github.ref_name == github.event.repository.default_branch }}
221+ name : PHP ${{ steps.version.outputs.PHP_VERSION }} for PM5
222+ tag : ${{ steps.version.outputs.PHP_VERSION }}-pm5
241223 commit : ${{ github.sha }}
242- bodyFile : ${{ github.workspace }}/changelog.md
243- prerelease : ${{ endsWith(github.ref_name, '-preview') }}
244-
224+ allowUpdates : true
225+ removeArtifacts : true
226+ prerelease : ${{ endsWith(github.ref_name, '-preview') }}
0 commit comments