1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Implemented Template diff comparison indicator / editor

Discussion in 'Closed Suggestions' started by Trombones13, Dec 15, 2010.

  1. Trombones13

    Trombones13 Well-Known Member

    I don't know about IPB, but in vBulletin, if you've edited a template, you're able to click "View Original" to see what changes are made. I've been missing this function as I've been editing on XF, particularly when going back and trying to see what I've actually changed in the template. The View Original option would highlight what parts of the code you've added or subtracted from the original, making it easy to compare the original and the current versions at a glance. I think that adding that option would make it much easier for style developers and those tweaking their templates for other various reasons. :)
    Marcus, bambua, Andy To and 13 others like this.
  2. danielwerner

    danielwerner Active Member

    I agree, and preferably with highlight yes. :)
    krstep and anotheralias like this.
  3. anotheralias

    anotheralias Well-Known Member

    Oh good, I asked about that awhile back but nobody ever replied.
  4. Kim

    Kim Well-Known Member

    IPB does have this, it is of limited value for a number of reasons;

    The pop up window with the information sits over the top of the template window, and cannot be moved out of the way, so you can't live edit your actual template using the pop up as a guide....on xen this actually wouldn't be so bad as they don't have huge code templates, but on IPB it is really difficult to use that way.

    and as I have already mentioned elsewhere... lol

    Just make the "added" and "removed" highlight colours sufficiently different and not red/ green colour blind non readable :D hehehe
  5. Brogan

    Brogan XenForo Moderator Staff Member

    Title edited :)

    I'm not sure if you're aware but Notepad++ has a great file compare feature which does exactly this.
    I know this is a suggestion for the core software but in the meantime/if it doesn't get included, just thought I'd let you know this is possible.

    Jo., Trombones13, Peggy and 1 other person like this.
  6. Peggy

    Peggy Well-Known Member

    Wonderful. How do you go about opening these up in Notepad++ Brogan?
  7. Brogan

    Brogan XenForo Moderator Staff Member

  8. Peggy

    Peggy Well-Known Member

    I did download notepad++ a couple of days ago when you told me to. Just don't know how to use it yet. :)
  9. Trombones13

    Trombones13 Well-Known Member

    Awesome; thanks, Brogan! I'll check that out. :)
  10. Miko

    Miko Well-Known Member

    I don't think this feature will ever be included in XenForo (I might be wrong) as WebDav is so much more powerful compared to any other forum template system.

    Why would you want to compare templates and work in the admin text editor when you can do all of your template edits, comparison, version history locally using your favorite code editor?

    Workflow (once you know hot to use WebDav) is faster and better! No web editor will ever compare to the raw speed and feature of a normal application.

    Just to give you an idea i have a very complex style with at least 20 templates changes and using WebDav I can normally upgrade it in around 10/15 minutes.

    The same style would have taken me almost 1 hour to upgrade in vBulletin using the built in template history.

    If you don't know how to use WebDav, Kier posted a screencast some time ago or feel free to ask and I'll be happy to give you a hand :)
    Trombones13 and Shelley like this.
  11. Brogan

    Brogan XenForo Moderator Staff Member

    Isn't that only available with paid editors though Miko?

    Does it work with Notepad++ for example?
  12. Miko

    Miko Well-Known Member

    WebDav can be used with many free FTP clients too.

    All you have to do is connect and then you can simply edit the templates.

    You can even download entire styles and master styles as a directory with all the templates as separate HTML files for historical record :)

    OS X and Windows can also connect natively to WebDav but I highly recommend NOT to use them as both implementation are slow and buggy and will result in errors!
  13. Trombones13

    Trombones13 Well-Known Member

    I didn't know about it when I had posted, but that's a great tip--thanks! Even using Notepad++ as Brogan mentioned was helpful, but I'll definitely have to check that out. :D
  14. Miko

    Miko Well-Known Member

    If you run into problems feel free to give me a buzz, good luck :)
    Shelley likes this.
  15. Wootalyzer

    Wootalyzer Active Member

    I'd like to add that automatic merging of patches for templates during upgrades is a god-send. One click and *poof*, all your custom templates are upgraded for you (except for the occasional merge issue).

    Of course, just a simple diff would come first - but eventually, auto-merging would be a great feature to have.

    Edit: I just saw the posts regarding webdav - yes, it would be great for diff-ing on your own, but you still don't have an easy way to find the updates to the stock template within the past few versions.
  16. Miko

    Miko Well-Known Member

    Don't want to be look like I'm challenging everyone here, but automatic merging are always causing more problems than not.
    No system can be that intelligent to know what I have done or moved in templates, most of the time casing more work than doing it manually in first place.

    To compare current master to a previous version is very simple, download the master template in WebDav before doing an upgrade and then compare it with the new one ;)

    Beta 5 VS Beta 6

    Trombones13 likes this.
  17. Jaxel

    Jaxel Well-Known Member

    I use BeyondCompare3... I think its a bit better than the built in diff comparison with Notepad++

    Also... automatic merging of patches for templates is AWFUL. I never want to see it. EVER.
    Miko likes this.
  18. Brogan

    Brogan XenForo Moderator Staff Member

    I've used Notepad++ for years so if someone knows how to hook it up via WebDav, I'd be grateful for some pointers.
  19. Wootalyzer

    Wootalyzer Active Member

    That's not inconvenient at all :p. Perhaps someone should setup www.downloadoldxenforotemplates.com ;)

    To each his own - I find it very convenient to review the merge, fix any little issues, and commit. Rather than open old versions of the templates, upgrade the bb, open the new versions of the templates, open my versions of the templates, check the diff, and apply each part of the diff manually to each one.
  20. bogus

    bogus Guest

    I just recognized the new Alert "There are templates that may be outdated. Click here to review them."
    which is good to have but i made so many changes to different Templates that i need days to get all insert into the new Templates.
    Wouldnt it be better to implement an option that shows the original and outdated Template, instead of eg.: PAGE_CONTAINER Custom Version: 1.0.0 Beta 5, Master Version: 1.0.0 Beta 6

    Sry for the bad Title, was a bit in a hurry while pressing the Trigger [​IMG]

Share This Page