Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Auto versioning based on detected changes #37

Closed
moppa opened this issue Jul 16, 2014 · 5 comments
Closed

Auto versioning based on detected changes #37

moppa opened this issue Jul 16, 2014 · 5 comments

Comments

@moppa
Copy link

moppa commented Jul 16, 2014

The wiki page on versioning mentions Auto versioning based on detected changes
https://github.com/Shandem/ClientDependency/wiki/Versioning

"Coming soon..." last updated April 2013 - Any update on this?

We are using a CMS (Umbraco) and our users will edit the CSS and JS on the live site quite extensively. Currently you can only invalidate the cache by changing versioning number, is this correct?

@Shazwazza
Copy link
Owner

When running in non-debug mode you'll have to modify the version number. Due to the way CDF works and requiring support for load balanced environments, it's quite difficult to 'detect' changes. The only real way would be to store the cdf version in a txt file (not in an asp.net config file so the app doesn't restart) and then allow for some startup config to allow a developer to specify a file watch pattern and auto change the version when file changes are detected. Its certainly possible, just haven't had the time to really look in to this.

@mccallsolutions
Copy link

On a related versioning note: What is the difference between the version attribute in the web.config and ClientDependency.config? It seems the web.config one is used, but correct me if I'm wrong it use to use the version in ClientDependency.config?

@Shazwazza
Copy link
Owner

Hi @mccallsolutions , I think you have an installation bug happening. If you are using Umbraco which I'm assuming you are because you have ClientDependency.config. Somewhere along the lines a nuget upgrade would have removed the web.config link to this file which you'll need to fix.

  • YOu should have this declared in your web.config:
<section name="clientDependency" type="ClientDependency.Core.Config.ClientDependencySection, ClientDependency.Core" requirePermission="false" />         
  • Then you CDF section should simply look like this:
<clientDependency configSource="config\ClientDependency.config" />    

which points the config to the external config file.

@mccallsolutions
Copy link

Brilliant - thanks!

@Shazwazza
Copy link
Owner

related #175

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants