1

I'm currently developing with Umbraco, which is great for my needs. However, I also take a lot of care to always put everything into my SVN repository, so I can revert when necessary.

So, right now, I run my Umbraco installation locally on my computer, and write my Razor scripts and my user controls on this computer. When it all works fine, I check it into my repository and upload it to the server.

Working like this has its advantages, but also its disadvantages. I can forget to upload a file, and see everything crash, for instance.

So I was wondering if it is possible to work on a site that is on the server and retroactive check in all changes I made to masterpages, script files, ...

Are there any tools that work in this direction? Anything you can think of?

Steven Lemmens
  • 1,441
  • 3
  • 17
  • 30
  • SVN post-commit hook script maybe? If you are on Windows see the http://stackoverflow.com/questions/11540298/how-to-export-revision-on-commit-with-a-post-commit-hook – bahrep Oct 02 '12 at 15:11
  • Isn't that the other way around? I want to go from a change on the server to an SVN commit ... – Steven Lemmens Oct 02 '12 at 15:28

1 Answers1

0

You should check out the events on the Umbraco APIs in the cms.dll (umbraco.cms.businesslogic namespace) - there are events for media saves (Media.AfterSave), documents (Document.AfterSave), masterpages, macros, and so on. I suggest you look at these events and then look at writing hooks into a library such as SharpSvn to automatically check stuff into your SVN repository post-save.

Jamie Howarth
  • 3,273
  • 3
  • 20
  • 26