CodeSleeve / asset-pipeline

This Laravel 4 package provides a very simple and easy to use asset pipeline. It was heavily inspired by the Rails asset pipeline. We make use of the wonderful Assetic package to help with pre-compliation!
http://www.codesleeve.com
MIT License
489 stars 53 forks source link

[Question] updates when the cache files ones is not updated? #138

Closed gullitmiranda closed 10 years ago

kdocki commented 10 years ago

lol, I don't understand the question...

gullitmiranda commented 10 years ago

when I change the files required in the main, it is not a concatenation automatically. nescessido change and save the main file.

kdocki commented 10 years ago

So when you change a file that is required by your manifest it does not break the cache for you? Can you paste your manifest here and also your config.php (if you have one published).

gullitmiranda commented 10 years ago

but the cache is not updated. only updates when the file named by helper undergoes changes. How to put in config.php I do not quite understand.

kdocki commented 10 years ago

@gullitmiranda say you have this inside of application.js

//= require foo.js

When you change foo.js it should break the cache for application.js when you are concatenating. Are you not seeing this behavior?

gullitmiranda commented 10 years ago

exactly.

application.js

//= require jquery
//= require angular

//= require_tree controllers
kdocki commented 10 years ago

@gullitmiranda what version of pipeline are you using? Do you have a app/config/packages/codesleeve/asset-pipeline/config.php file? If you are changing files inside of the controllers directory then it should be busting the cache for you. I have tested this and it is working so I'd like to know more about your setup.

kdocki commented 10 years ago

@gullitmiranda Also what do you have in app/storage/cache/asset-pipeline?

gullitmiranda commented 10 years ago

Yes, have app/storage/cache/asset-pipeline.

I have no app/config/packages/codesleeve/asset-pipeline/config.php.

My structure is as follows: application.js carry the main file and load it inside the other, if I'm ordering you to charge the controllers folder and plugins.

kdocki commented 10 years ago

@gullitmiranda can you do a dd(App::environment()) for me? if you are on production then pipeline is going to cache files. You need to set your environment to something like local or develeopment

gullitmiranda commented 10 years ago

Forgiveness, I'm new in laravel, then where do I set the environment as local or development?

gullitmiranda commented 10 years ago

I can only do the dd (App :: environment ()) on Monday because the development environment is the only machine in the office.

kdocki commented 10 years ago

Check out https://github.com/CodeSleeve/asset-pipeline#installation

Also this stack overflow; http://stackoverflow.com/questions/20669462/changing-default-environment-in-laravel-4

kdocki commented 10 years ago

Did setting the environment fix it for you?

gullitmiranda commented 10 years ago

dd(App::environment()) return:

string 'local' (length=5)
gullitmiranda commented 10 years ago

Yes, the environment setting solved my problem.

tanks