lundi 3 juillet 2017

What are the best practices to clone a project from git?

Imagine if you have a laravel project in your local computer and you pushed that project to git(github,gitlab,etc..). That project is already equipped with several new libraries while developing in local. Now, if you clone this project in a remote server(say digitalocean or aws), you'll get errors regarding libraries and extensions. For example, ".env" file is avoided by default in ".gitignore". In this case, you'll get some encryption error. So, is it better to clone the entire project and solve the errors one by one? Or is it better to install a new laravel application and libraries and pull only coding part? If so, what is the order?

case 1
a. Clone (git and remote server will be linked)
b. Remove project and install fresh laravel application and libraries
c. Pull for coding part

case 2
a. First install fresh laravel application and libraries
b. Now clone or pull coding part from git server
c. Commit changes

I know step b is wrong in both the cases. 

Can anyone please guide me through this. Thanks in advance.



via Chebli Mohamed

Aucun commentaire:

Enregistrer un commentaire