Skip to content

Commit 3b17759

Browse files
committed
update to 3.0
1 parent 12ee1ac commit 3b17759

File tree

3 files changed

+39
-6
lines changed

3 files changed

+39
-6
lines changed

composer.json

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,19 @@
11
{
22
"name": "zhamao/framework-starter",
33
"description": "composer project of zhamao-framework-starter",
4-
"minimum-stability": "stable",
4+
"minimum-stability": "dev",
55
"license": "Apache-2.0",
6-
"version": "2.5",
6+
"version": "3.0",
77
"type": "project",
88
"prefer-stable": true,
99
"require": {
10-
"zhamao/framework": "^2.4"
10+
"zhamao/framework": "^3.0"
1111
},
1212
"require-dev": {
1313
"swoole/ide-helper": "@dev"
1414
},
1515
"scripts": {
16-
"post-create-project-cmd": "vendor/bin/start init",
17-
"post-update-cmd": "vendor/bin/start check:config"
16+
"post-create-project-cmd": "vendor/bin/zhamao init",
17+
"post-update-cmd": "vendor/bin/zhamao check:config"
1818
}
19-
}
19+
}

zhamao

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
#!/bin/sh
2+
3+
# shellcheck disable=SC2068
4+
# shellcheck disable=SC2181
5+
# author: crazywhalecc
6+
# since: 2.5.0
7+
8+
if [ "$ZM_CUSTOM_PHP_PATH" != "" ]; then
9+
echo "* Using PHP executable: ""$ZM_CUSTOM_PHP_PATH"
10+
executable="$ZM_CUSTOM_PHP_PATH"
11+
elif [ -f "$(pwd)/runtime/php" ]; then
12+
executable="$(pwd)/runtime/php"
13+
echo "* Framework started with built-in php."
14+
else
15+
which php >/dev/null 2>&1
16+
if [ $? -eq 0 ]; then
17+
executable=$(which php)
18+
else
19+
echo '[ErrCode:E00014] Cannot find any PHP runtime, please use command "./install-runtime.sh" or install PHP manually!'
20+
exit 1
21+
fi
22+
fi
23+
24+
if [ -f "$(pwd)/src/entry.php" ]; then
25+
$executable "$(pwd)/src/entry.php" $@
26+
elif [ -f "$(pwd)/vendor/zhamao/framework/src/entry.php" ]; then
27+
$executable "$(pwd)/vendor/zhamao/framework/src/entry.php" $@
28+
else
29+
echo "[ErrCode:E00015] Cannot find zhamao-framework entry file!"
30+
exit 1
31+
fi

zhamao.bat

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
@echo off
2+
php .\src\entry.php %*

0 commit comments

Comments
 (0)