Vendor:Publish - Nothing to publish for tag [] - Only on production server

怎甘沉沦 提交于 2019-11-29 00:46:18

问题


I am using a third party library and locally, I installed everything using the steps that they provided.

  1. I ran composer require on the package and ran an update. This installed into the vendor folder.
  2. I then added the path into the provider in config/app and also as an aliases..
  3. I ran php artisan vendor:publish --provider="Spatie\LaravelAnalytics\LaravelAnalyticsServiceProvider" the config file created successfully and I had no problems.
  4. I then uploaded to the production environment and kept on getting Class 'LaravelAnalytics' not found and I can't seem to figure out the problem..

  5. I ran php artisan vendor:publish --provider="Spatie\LaravelAnalytics\LaravelAnalyticsServiceProvider"

But I kept on getting: Nothing to publish for tag []. which has lead me to thinking that this could be the problem since the package is not published.

My local environment is Ubuntu and my production Environment is CentOS.. If I try to CD into that directory on my production environment it says cannot find.

Could this therefore be a problem with the case sensitive on how I am adding my providers that is not picking up this package?


回答1:


are you using cached config files ? try using

php artisan config:clear

and retry

php artisan vendor:publish



回答2:


You have to save all for the project before (php artisan vendor:publish).



来源:https://stackoverflow.com/questions/32090564/vendorpublish-nothing-to-publish-for-tag-only-on-production-server

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!