File tree Expand file tree Collapse file tree 1 file changed +8
-3
lines changed
Expand file tree Collapse file tree 1 file changed +8
-3
lines changed Original file line number Diff line number Diff line change @@ -24,8 +24,12 @@ if [ -z $homedir ]; then
2424 check_result $E_NOTEXIST " Error: user home directory doesn't exist"
2525fi
2626
27- realcmd=" $( which " $clicmd " ) "
28- check_result $? " Unknown cli command" $E_NOTEXIST
27+ if [ " $clicmd " = " composer" ]; then
28+ realcmd=" $homedir /.composer/composer"
29+ else
30+ realcmd=" $( which " $clicmd " ) "
31+ check_result $? " Unknown cli command" $E_NOTEXIST
32+ fi
2933
3034if [ ! -x " $realcmd " ]; then
3135 check_result $E_NOTEXIST " Error: Cli command does not exist"
@@ -49,7 +53,8 @@ if [ "$realcmd" != '/bin/ps' -a \
4953 " $realcmd " != ' /usr/bin/php7.1' -a \
5054 " $realcmd " != ' /usr/bin/php7.2' -a \
5155 " $realcmd " != ' /usr/bin/php7.3' -a \
52- " $realcmd " != ' /usr/bin/php' ]; then
56+ " $realcmd " != ' /usr/bin/php' -a \
57+ " $clicmd " != ' composer' ]; then
5358 check_result $E_FORBIDEN " Error: Cli command not enabled"
5459fi
5560
You can’t perform that action at this time.
0 commit comments