Search code examples
phplaravelxamppbitbucketatlassian-sourcetree

How to clone a laravel project form bitbucket and install and run in your computer with Sourcetree?


I want full step to step work to clone a laravel project in my computer and also to run it properly !


Solution

  • Check your php,composer version & git

    • Click Ctrl + r and type cmd
    • Type php -v to check your php version in your command line.
    • [If your php version is more than 5.6 you are good to go ! ]
    • [If your php is not installed or even php version is less than 5.6, then store your htdocs from Xampp and uninstall Xampp. Then install Xampp. Link is given below https://www.apachefriends.org/download.html]
    • Type composer -v to check your composer version in your command line
    • Typecomposer update
    • [If composer is not installed,then download and install it. Link is given bellow https://getcomposer.org/download/]
    • Type git
    • [If git is not installed,then download and install it. Link is given bellow https://git-scm.com/downloads ]

    Sourcetree Authentication with bitbucket Repository

    Run your Laravel project cloning from Bitbucket Repository

    • Now,just clone your project in your preferred location.

    • Open your project in PhpStorm (or any other IDE you prefer).

    • copy .evn.example file in a new .evn file in that folder. Edit DB_DATABASE, DB_USERNAME, DB_PASSWORD

    • Create a folder naming framework in storage folder. then create 3 folders naming sessions,views,cache in framework folder.

    • open IDE terminal.

    • Type composer update

    • Type php artisan key:generate

    • Type php artisan config:clear

    • Type php artisan route:clear

    • Type php artisan view:clear

    • Type php artisan migrate

    • Type php artisan serve

    • Open browser type localhost:8000

    Ta Da !!! Your project is running fine in your browser.