Configuration of existing yii project

Hi,

I am running an existing Yii project which does not contain the Yii executable file and as a result, I am unable to run php yii server

To fix this I have re-written the content of the Yii file with the solution from the following link

https://github.com/yiisoft/yii2/issues/12654

I then ran. php yii serve

This gave me the following output

#!/usr/bin/env php
PHP Fatal error:  Cannot declare class yii\BaseYii, because the name is already in use in /Volumes/MirieriD/AdggPlatform/adgg-backend/src/vendor/yiisoft/yii2/BaseYii.php on line 60

Fatal error: Cannot declare class yii\BaseYii, because the name is already in use in /Volumes/MirieriD/AdggPlatform/adgg-backend/src/vendor/yiisoft/yii2/BaseYii.php on line 60

What is it? Is it yours, or someone else’s?

Do you mean yii console bootstrap file that exists on the root directory of the project?

What exactly did you write? Can you show us the content of it?