No announcement yet.

Feature Request - Load/Save Session Replacements?

  • Filter
  • Time
  • Show
Clear All
new posts

  • Feature Request - Load/Save Session Replacements?

    Would it be possible to have the ability to save and load Session Replacements ? ...Without having to same them as part of a session?

    For example,

    I've compared 2 directories of similar files with lots of known/acceptable differences, I've added a lot of Replacements, so now I can see the real important differences.

    I then want to do the same kind of task again on another couple of directories/files at a future date. I don't want this to be the default session settings, I want to choose when I want to apply them depending on the file I'm comparing in my current folder comparison.

    I also don't want to clutter up my sessions window with lots of (temporary) saved sessions, and then have to edit their folder paths just so I can use my pre-done replacements.

    A nice import/export button (along with the New/Clone/Edit/Delete buttons) would do nicely please!
    Last edited by LovellyJubblies; 22-Feb-2011, 10:35 AM. Reason: More meaningful title

  • #2
    Hello Barry,

    Thanks for the suggestion. An easier method of ad hoc replacement setting is on our Customer Wishlist.

    Could you go into more specifics on what types of replacements you are using in one scenario but not another?
    The workaround now would be to use sessions without paths set, but it sounds like you are using Folder Compare sessions, then opening Text Compare sessions and defining Text Replacements for "All Files within Parent Session." Is this accurate?
    Aaron P Scooter Software


    • #3

      " sounds like you are using Folder Compare sessions, then opening Text Compare sessions and defining Text Replacements for "All Files within Parent Session." Is this accurate?"

      Yes, that's how I've ended up doing it for the moment, and I then once I've finished with one pair of directories, I'm browsing the left and right side to point them at another pair of directories to compare their files which keeps my replacements. Bit fiddly, but it worked well enough for now.

      Here's an example...

      Say you've got some C# code. You're doing classes for different cars. So all are based on a common theme of car. Common code etc.

      So, we've got directories for Jaguar, Ford, Vauxhall, Toyota, etc.

      I've also got language specific versions, so within Jaguar, I've got subdirectories for English, Spanish, etc

      So I'm comparing say the "Jaguar English" directory containing files like "English.Jaguar.Engine.cs" etc, with "Jaguar Spanish" directory containing files like "Spanish.Jaguar.Engine.cs" etc

      I right click on the directories, and compare the folders. Nothing lines up.

      So I use the Alignment Override on the session to line up all the "*.Jaguar.*.cs" files (so "English.Jaguar.Engine.cs" lines up with the corresponding "Spanish.Jaguar.Engine.cs" file)

      So far so good. But the files all look like they've got lots of differences.

      Then I can play spot the difference in my code, BUT I'm stuck with Spanish and English translations which I'm not interested in from a code difference perspective. I can't see the real important differences.

      I then double click to view file differences between "English.Jaguar.Engine.cs" and "Spanish.Jaguar.Engine.cs", and I want to ignore the English/Spanish differences. I use Replacements to have my English to Spanish equivalents, so "blue" in English would be (google translate to the rescue) "azul" etc

      Now I can ignore those, and see just where my code is potentially wrong where I've changed things in one class/directory, but forgot to do in another directory. (Yeah I know you'd say put common code in a base class, but this is an example!! ;-) )

      I want to save out those English/Spanish Replacements so I can reuse for other cars/directories, or I may want to load up the English/French replacements that my colleague has just done (and perhaps EMailed me?!). Or save them off for another day.




      • #4
        Thanks, Barry. That's a great example. I'll add it to our notes.

        For now, the only workaround is your colleague can save his parent session and email it to you. You would still need to load/clone the parent session first, and then use it for the comparison.
        Aaron P Scooter Software


        • #5
          Okay, thanks.

          p.s. We use BC3 (pro) extensively - standalone for files/folders, website (FTP) sessions, and also tied in with TortoiseSVN for it's 2 way diff and 3 way merge.

          I've probably said before, simply brilliant. (I'm jokingly accused here by my colleagues of being on commission for you or something!)


          • #6
            I presume nothings happening on this so far, so I thought I'd post a work around....

            Edit BCSessions.xml, in the bottom section, there's <TSessionFolder><Items><TTextCompareSession> ..... </TTextCompareSession>

            This has your default session stuff for a text compare. I'd put all my spanish replacements in the default, so this had my replacements. So I copied this as <TTextCompareSession2>...</TTextCompareSession2>. Saved. BC3 will ignore this.

            I then ran BeyondCompare and deleted all my spanish replacements in the defaults, and again saved. (It actually deleted the whole <TTextCompareSession> thing, so looks like it'll only have this if you have replacements.

            As/when you want spanish replacements, or whatever set(s) you have, you can just copy your <TTextCompareSession2> as <TTextCompareSession>, and your replacements will be there for use.

            So by default, mine is empty, but when I'm doing spanish stuff, then I'll grab my <TTextCompareSession2> and use it.

            Fiddly, but until we can Import/Export/Load/Save/whatever replacements, or perhaps be able to choose a default session type, this is the best way I've found of having selective replacements.



            • #7
              Thanks, Barry. This item is still something on our Customer Wishlist. I hope this information is useful for anyone coming across this forum post in the meantime.
              Aaron P Scooter Software