Skip to content

Commit 749fc70

Browse files
authored
upgrade
1 parent 3448871 commit 749fc70

File tree

4 files changed

+79
-274
lines changed

4 files changed

+79
-274
lines changed

.github/workflows/build.yml

Lines changed: 71 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,71 @@
1+
name: Build Custom EasyEngine
2+
3+
on:
4+
push:
5+
branches: [ "develop" ]
6+
workflow_dispatch:
7+
8+
jobs:
9+
build:
10+
name: Build Phar
11+
runs-on: ubuntu-latest
12+
steps:
13+
- name: Check out source code
14+
uses: actions/checkout@v4
15+
16+
- name: Clean environment
17+
run: |
18+
rm -rf vendor composer.lock
19+
20+
- name: Set up PHP
21+
uses: shivammathur/setup-php@v2
22+
with:
23+
php-version: '8.3'
24+
coverage: none
25+
tools: composer
26+
extensions: pcntl, curl, sqlite3, zip, dom, mbstring, json, phar
27+
28+
- name: Setup Composer authentication
29+
run: |
30+
composer config -g github-oauth.github.com ${{ secrets.GITHUB_TOKEN }}
31+
composer config --global --auth github-oauth.github.com ${{ secrets.GITHUB_TOKEN }}
32+
composer config -g repo.packagist composer https://packagist.org
33+
34+
- name: Install dependencies
35+
run: |
36+
composer install --prefer-dist --no-dev --no-progress --no-interaction --optimize-autoloader
37+
composer dump-autoload --optimize --classmap-authoritative
38+
39+
- name: Prepare for PHAR build
40+
run: |
41+
# Copy required files to temporary directory
42+
mkdir -p phar-build
43+
cp -r php bin utils VERSION vendor phar-build/
44+
45+
- name: Build uncompressed PHAR
46+
run: |
47+
cd phar-build
48+
php -dphar.readonly=0 ../utils/make-phar.php easyengine.phar --no-compression
49+
chmod +x easyengine.phar
50+
mv easyengine.phar ../
51+
cd ..
52+
53+
- name: Test PHAR
54+
run: |
55+
php easyengine.phar cli info
56+
57+
- name: Create Git tag
58+
id: tag
59+
run: |
60+
DATE=$(date +%Y%m%d)
61+
COMMIT_SHORT=$(git rev-parse --short HEAD)
62+
echo "TAG=v4.0.0-custom-$DATE-$COMMIT_SHORT" >> $GITHUB_OUTPUT
63+
git tag $TAG
64+
git push origin $TAG
65+
66+
- name: Create Release
67+
uses: softprops/action-gh-release@v1
68+
with:
69+
tag_name: ${{ steps.tag.outputs.TAG }}
70+
files: easyengine.phar
71+
token: ${{ secrets.GITHUB_TOKEN }}

.github/workflows/test_and_build.yml

Lines changed: 0 additions & 272 deletions
This file was deleted.

VERSION

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
4.9.0
1+
4.9.0

composer.json

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,12 @@
2626
},
2727
"minimum-stability": "dev",
2828
"prefer-stable": true,
29+
"repositories": [
30+
{
31+
"type": "vcs",
32+
"url": "https://github.com/dinhngocdung/site-command"
33+
}
34+
],
2935
"require": {
3036
"php": ">=7.0",
3137
"composer/composer": "2.2.24",
@@ -40,7 +46,7 @@
4046
"easyengine/mailhog-command": "v1.0.3",
4147
"easyengine/service-command": "v1.6.1",
4248
"easyengine/shell-command": "v1.1.3",
43-
"easyengine/site-command": "v3.4.0",
49+
"easyengine/site-command": "dev-develop",
4450
"easyengine/site-type-php": "v1.9.2",
4551
"easyengine/site-type-wp": "v1.9.1",
4652
"monolog/monolog": "1.24.0",

0 commit comments

Comments
 (0)