Cant install Grav

Hello! Im trying to install grav, so cloned form Git, no problems. Then running bin/grav install and here it is -

PHP Parse error: syntax error, unexpected T_STRING, expecting T_CONSTANT_ENCAPSED_STRING or ‘(’ in /bin/grav on line 13

My CLI - PHP 5.6.5-pl0-gentoo (cli) (built: Jul 13 2015 18:52:22)

Same issue with any Grav CLI command
Any suggestions?

First, the simplest way to install Grav is with the pre-built package, as it contains everything you need, just unzip and point your browser at it. Those are available in the downloads site or in the “releases” tab of github.

Second, a parse error usually means an older version of PHP. Can you confirm you are running PHP 5.6 as you say? just type php -v from your terminal.

If you look at line 13 of bin/grav you will see it just says: use Grav\Common\Composer;

The error you are seeing is something you would see if you were running < PHP 5.3: http://stackoverflow.com/questions/13960277/error-parse-error-syntax-error-unexpected-t-string-expecting-t-constant-encap

@rhukster, Originally php -v results 5.2 version (only CLI, phpinfo gives me PHP Version 5.6.5-pl0-gentoo). but my hosting provider recommend me to use these commands to change it:
echo “alias php=/usr/lib64/php5.6/bin/php” > ~/.bashrc
source ~/.bashrc

But bin/grav list command (for example) gives me the same old error (trying on zipped version now). Its strange!

Finally worked! Thanks for help

No problems :slight_smile: Glad you got it sorted