search

Home  >  Q&A  >  body text

I want to put my laravel project on Github, what files should I upload?

Looking at other people’s warehouses, everyone’s file directories are different...
My project directory:

I hope the respondent can explain why some files do not need to be uploaded~~Thank you!

PHPzPHPz2795 days ago533

reply all(2)I'll reply

  • 阿神

    阿神2017-05-02 09:30:36

    bootstrap/cache cache file directory generated when the program is running
    Files in the storage subdirectory, these files are also files generated when the program is running
    .env local configuration file, this depends on the specific environment, so no version management is required

    vendor and composer.lock This is a file generated by composer. This depends on the situation. Generally speaking, composer.lock needs to be uploaded, which is considered to unify the version of the external library used by the program. The vendor directory can be ignored, but if external network access is restricted, it can also be uploaded.

    reply
    0
  • 过去多啦不再A梦

    过去多啦不再A梦2017-05-02 09:30:36

    Reference link: Laravel.gitignore

    GitHub has a very detailed .gitignore
    file list for dozens of projects and languages, you can find it at https://github.com/github/gitignore
    .

    reply
    0
  • Cancelreply