Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Nic Wise 51 posts 85 karma points
    Sep 13, 2010 @ 12:46
    Nic Wise
    0

    Document Types (and other settings) in SVN

    Hi there

    I've been googleing around a fair bit trying to find a solution to this.

    Basically, we need to put everything in source control except maybe content. masterpages, css, js etc are all easy. Document Types are not, neither are the settings for macro's.

    The only option I can see is to manually export them (or make a package), unzip the package file and version that. Not exactly nice, but it'll work if people remember to do it.

    However, I'd love a command line tool to do the package export and import - so we can maybe do it via Team City (CI tool). Anyone done this?

    Thanks

    N

  • Ismail Mayat 4379 posts 9526 karma points MVP 2x admin c-trib
    Sep 13, 2010 @ 13:46
    Ismail Mayat
    0

    Nic,

    With regards to document types i do recall seeing something from Shannon and Slace they implemented action handler to export out xml of doc type on change and that was then being versioned cant see to find the post.

    Regards

    Ismail

  • Nic Wise 51 posts 85 karma points
    Sep 13, 2010 @ 13:50
    Nic Wise
    0

    Thanks Ismail, I'll have a hunt around - that sounds like a good idea - make a documenttype folder, and export to there on save.

    Nice!

  • Steen Tøttrup 191 posts 291 karma points c-trib
    Sep 13, 2010 @ 13:51
    Steen Tøttrup
    0

    I've been working on a solution for this (doc type, macros, etc etc.), but work has put an end to this project lately.

    A quick fix would be to export doc types (to xml) on the onchange event, and you could put up a filesystemwatcher to catch when a file was changed (put it in a folder where only the xml files of the doc types are located), and overwrite the xml of the doc type.

    I guess you could do something quick for macros too.

    The solution I've been working on involves a lot of UI work etc, so no chance of me finishing it in the near future.

     

  • Shannon Deminick 1494 posts 5045 karma points hq
    Sep 13, 2010 @ 13:58
    Shannon Deminick
    0

    Yeah, i can't remember the post either but essentially the idea is:

    Bind to events in Umbraco to save out a serialized version of Document types, macros, dictionary, etc... which can then be saved to source control. Our Snapshot product (which will hopefully have a beta program launched soon) already does all of this serialization for you with the command line.

    The tricky part is if you want to try to restore an umbraco instance based on this.... which we haven't written. The tricky part of this is that if you have references to exact node IDs in your config, pickers, etc.... doing a restore from data will create new ids.

  • Steen Tøttrup 191 posts 291 karma points c-trib
    Sep 13, 2010 @ 14:07
    Steen Tøttrup
    0

    I got that part working too!

    Maybe I should release what I got, and instead of developing an UI, just hook it up with event handlers.

  • Aaron Powell 1708 posts 3043 karma points c-trib
    Sep 13, 2010 @ 14:40
    Aaron Powell
    0

    Here's the article Shan is referring to: http://farmcode.org/post/2010/06/11/Backing-up-Document-Types.aspx

  • Nic Wise 51 posts 85 karma points
    Sep 13, 2010 @ 17:44
    Nic Wise
    0

    Thanks everyone, thats a great help.

    Cheers

    Nic

Please Sign in or register to post replies

Write your reply to:

Draft