Community
    • Login

    [New Plugin] ComparePlus v1.0.0

    Scheduled Pinned Locked Moved Notepad++ & Plugin Development
    30 Posts 11 Posters 33.7k Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • Michael VincentM
      Michael Vincent @pnedev
      last edited by

      @pnedev said in [New Plugin] ComparePlus v1.0.0:

      • Can run files compare directly when starting Notepad++ from the command line (notepad++ -pluginMessage=“compare” old_file.txt new_file.txt)

      Command line usage? Are you serious!?!?! OMG, it works! You’ve outdone yourself!

      I’ve been using your incremental builds of ComparePlus along the way to get used to it in preparation for switching from the old Compare Plugin … This is great!

      Cheers.

      Alan KilbornA 1 Reply Last reply Reply Quote 6
      • YaronY
        Yaron @pnedev
        last edited by

        Hello my friend Pavel,

        “Those who sow in tears shall reap in joy.”
        Thank you for patiently and meticulously sowing.
        Thank you for the tears.
        And thank you for sharing the harvest and joy.

        On behalf of myself and many others: we appreciate you, your brilliant work and the masterpiece you have produced.

        Congratulations!

        1 Reply Last reply Reply Quote 5
        • SalviaSageS
          SalviaSage
          last edited by

          Congratulations Pavel on the development and the release of your plugin.
          I appreciate the effort and the time that you have put into it.
          I downloaded it and I think it can be a useful plugin.
          Thank you.

          1 Reply Last reply Reply Quote 4
          • Fruchtzwerg94F
            Fruchtzwerg94
            last edited by

            Awesome!
            For all of you who are looking for a link to the repo, like me, here it is: pnedev/comparePlus.

            1 Reply Last reply Reply Quote 4
            • Vitalii DovganV
              Vitalii Dovgan @pnedev
              last edited by

              @pnedev
              Thank you for the release!
              And I have a feature request :)
              This plugin adds 10 toolbar buttons. Could you add an option (or options) to select whether we want any button on the toolbar or, as an enhanced version, to specify which exact buttons we want or do not want on the toolbar? For example:

               -----------------------------------
              |  [ ] Show Toolbar buttons         |
              |      [ ] Set as First to Compare  |
              |      [ ] Compare                  |
              |      [ ] Compare Selections       |
              |      [ ] Clear Active Compare     |
              |      ...                          |
               -----------------------------------
              
              Alan KilbornA YaronY pnedevP 3 Replies Last reply Reply Quote 3
              • Alan KilbornA
                Alan Kilborn @Vitalii Dovgan
                last edited by

                @Vitalii-Dovgan said in [New Plugin] ComparePlus v1.0.0:

                This plugin adds 10 toolbar buttons.

                Wow, 10 toolbar buttons seems excessive. Maybe this would have been better served by having a dedicated panel for this plugin, similar in base concept to the panel in the Changed Lines plugin.

                1 Reply Last reply Reply Quote 0
                • YaronY
                  Yaron @Vitalii Dovgan
                  last edited by

                  @Vitalii-Dovgan,

                  Any reason not to use the CustomizeToolbar plugin?
                  IMO it’s a must-have plugin regardless of ComparePlus.

                  Vitalii DovganV 1 Reply Last reply Reply Quote 2
                  • pnedevP
                    pnedev @Vitalii Dovgan
                    last edited by

                    @Vitalii-Dovgan ,

                    I’ll consider your suggestion, thanks!

                    BR

                    1 Reply Last reply Reply Quote 3
                    • Alan KilbornA
                      Alan Kilborn @Michael Vincent
                      last edited by Alan Kilborn

                      @Michael-Vincent said in [New Plugin] ComparePlus v1.0.0:

                      Command line usage? Are you serious!?!?! OMG, it works!

                      I’m not able to get command-line use working.
                      I presume that it is supposed to load the files and then start the compare on them, but that’s just a presumption on how I think it should work; I haven’t seen anything that says that.

                      It loads the files, but doesn’t start the compare. The plugin itself loaded fine as I can see the toolbar buttons and I can start the compare manually, but…

                      I think I’m doing it correctly:

                      c1e9e026-a2ac-4882-81b2-dc7f2ef40b74-image.png

                      2637cf2d-ba7e-4f45-ab04-1594e3fbaaa0-image.png

                      Anyone have any hints for me?

                      pnedevP 1 Reply Last reply Reply Quote 2
                      • Bas de ReuverB
                        Bas de Reuver
                        last edited by

                        I use the old Notepad++ Compare plug-in almost daily. So it’s great news that you’re continuing its development and keeping it active and up-to-date.

                        I’ve seen other useful software tools slowly disappear due to software rot, so even if you hadn’t added new features I think it’s great just for the maintenance of such a useful utility 👍

                        1 Reply Last reply Reply Quote 4
                        • pnedevP
                          pnedev @Alan Kilborn
                          last edited by

                          @Alan-Kilborn ,

                          Try removing the quotes from compare - run it like that:

                          --pluginMessage=compare

                          Sorry for the misleading info in the description, my bad.

                          Alan KilbornA 2 Replies Last reply Reply Quote 4
                          • Vitalii DovganV
                            Vitalii Dovgan @Yaron
                            last edited by Vitalii Dovgan

                            @Yaron said in [New Plugin] ComparePlus v1.0.0:

                            @Vitalii-Dovgan,

                            Any reason not to use the CustomizeToolbar plugin?
                            IMO it’s a must-have plugin regardless of ComparePlus.

                            The CustomizeToolbar has two tiny issues which are actually not issues for most of people but are issues for me. First, CustomizeToolbar makes Notepad++'s toolbar to blink (repaint) during start-up. Second, CustomizeToolbar slows down Notepad++'s startup for almost a second (for a cold start). As I wrote, these are not issues for most of the people, but I’m very sensitive to such things.

                            1 Reply Last reply Reply Quote 1
                            • guy038G
                              guy038
                              last edited by guy038

                              Hello, @pnedev and All,

                              Ah… OK !. So the correct syntax is :

                              ...\notepad++ -pluginMessage=compare Old_file.txt New_file.txt

                              Howewer, we have to consider different cases. Let’s consider a session with two files change.log and copy.log ( with a few changes compared to change.log) and some other tabs, too :


                              • The change.log and copy.log tabs exist, both, in current N++ session AND the copy.log tab comes next to the change.log tab. After closing N++ :

                              => The CMD command ...\notepad++ -pluginMessage=compare change.log copy.log works correctly

                              => The CMD command ...\notepad++ -pluginMessage=compare copy.log change.log does not work correctly


                              • The change.log and copy.log tabs exist, both, in current N++ session AND the change.log tab comes next to the copy.log tab. After closing N++ :

                              => The CMD command ...\notepad++ -pluginMessage=compare change.log copy.log does not work correctly

                              => The CMD command ...\notepad++ -pluginMessage=compare copy.log change.log works corectly


                              • The change.log and copy.log tabs exist, both, in current N++ session BUT the copy.log tab and change.log tab are not adjacent. After closing N++ :

                              => The CMD command ...\notepad++ -pluginMessage=compare change.log copy.log does not work correctly

                              => The CMD command ...\notepad++ -pluginMessage=compare copy.log change.log does not work correctly


                              • The change.log tab only exists in current N++ session and is the last one. After closing N++ :

                              => The CMD command ...\notepad++ -pluginMessage=compare change.log copy.log works correctly

                              => The CMD command ...\notepad++ -pluginMessage=compare copy.log change.log does not work correctly


                              • The change.log tab only exists in current N++ session and is not the last one. After closing N++ :

                              => The CMD command ...\notepad++ -pluginMessage=compare change.log copy.log does not work correctly

                              => The CMD command ...\notepad++ -pluginMessage=compare copy.log change.log does not work correctly


                              • The copy.log tab only exists in current N++ session and is the last one. After closing N++ :

                              => The CMD command ...\notepad++ -pluginMessage=compare change.log copy.log does not work correctly

                              => The CMD command ...\notepad++ -pluginMessage=compare copy.log change.log works correctly


                              • The copy.log tab only exists in current N++ session and is not the last one. After closing N++ :

                              => The CMD command ...\notepad++ -pluginMessage=compare change.log copy.log does not work correctly

                              => The CMD command ...\notepad++ -pluginMessage=compare copy.log change.log does not work correctly


                              • The two tabs change.log and copy.log do not exist in current N++ session. After closing N++ :

                              => The CMD command ...\notepad++ -pluginMessage=compare change.log copy.log works correctly

                              => The CMD command ...\notepad++ -pluginMessage=compare copy.log change.log works correctly


                              Of course, all the previous cases happen if the current session contains, in addition, some tabs different from change.log AND copy.log

                              In the rare cases where the current session contains only the two files change.log and copy.log or one of the two or no file at all :

                              => The CMD command ...\notepad++ -pluginMessage=compare change.log copy.log works correctly in all cases

                              => The CMD command ...\notepad++ -pluginMessage=compare copy.log change.log works correctly in all cases


                              So, @pnedev, I suppose that you need to define the first file with the Set as First to Compare option and, probably, a new Set as Second to Compare option, used internally, to define the second file, in order that the DOS prompt command ...\notepad++ -pluginMessage=compare Old_file.txt New_file.txt always starts the comparison of the given files in all cases ?!

                              Best Regards,

                              guy038

                              pnedevP Alan KilbornA 2 Replies Last reply Reply Quote 3
                              • Alan KilbornA
                                Alan Kilborn @pnedev
                                last edited by

                                @pnedev said in [New Plugin] ComparePlus v1.0.0:

                                Try removing the quotes from compare - run it like that:
                                –pluginMessage=compare
                                Sorry for the misleading info in the description, my bad.

                                That works; thanks.

                                1 Reply Last reply Reply Quote 4
                                • pnedevP
                                  pnedev @guy038
                                  last edited by

                                  Hello @guy038 ,

                                  You are right. The command line compare works correctly only in case there is no auto-restored session. Otherwise it might mess things up.
                                  I’ll look into it for the next version, thanks.

                                  BR

                                  1 Reply Last reply Reply Quote 3
                                  • Alan KilbornA
                                    Alan Kilborn @guy038
                                    last edited by

                                    @guy038

                                    Maybe also test with the N++ argument -noSession ?

                                    1 Reply Last reply Reply Quote 2
                                    • guy038G
                                      guy038
                                      last edited by guy038

                                      Hi, @pnedev, @alan-kilborn, @yaron and All,

                                      @pnedev, don’t bother about my previous post ! No need to investigate further about the provided cases. The solution was obvious ! Always use the syntax :

                                      ...\notepad++ -nosession -pluginMessage=compare Old_file.txt New_file.txt

                                      BTW, @alan-kilborn, the parameter to use is -nosession ( and not -noSession ) !

                                      Best Regards

                                      guy038

                                      Alan KilbornA 2 Replies Last reply Reply Quote 3
                                      • Alan KilbornA
                                        Alan Kilborn @guy038
                                        last edited by

                                        @guy038 said in [New Plugin] ComparePlus v1.0.0:

                                        the parameter to use is -nosession ( and not -noSession )

                                        You’re right. However, I will take the opportunity to say that it is a bit odd that it is this way (all lowercase) when, -openSession (one I use often) is mixed case.

                                        1 Reply Last reply Reply Quote 3
                                        • Alan KilbornA
                                          Alan Kilborn @guy038
                                          last edited by Alan Kilborn

                                          @guy038 said in [New Plugin] ComparePlus v1.0.0:

                                          don’t bother about my previous post ! No need to investigate further about the provided cases. The solution was obvious

                                          I don’t know that I agree fully with that.

                                          It seems reasonable to want to do a command line compare and start the compare automatically between the 2 files where the files are loaded into a running Notepad++'s current session.

                                          Of course, a user doing this would probably want to close the 2 files when they are done analyzing the compare, to avoid the files remaining in the remembered session, but even that is not a certaintly.

                                          I suppose -nosession is ignored if N++ is already running (with a session) and another command line invocation of notepad++.exe occurs (without -multiInst).

                                          Maybe that’s the ultimate solution for something like a “git difftool” solution using this new plugin capability: using -multiInst -nosession -pluginMessage=compare…

                                          1 Reply Last reply Reply Quote 5
                                          • Alan KilbornA Alan Kilborn referenced this topic on
                                          • Alan KilbornA
                                            Alan Kilborn @pnedev
                                            last edited by

                                            @pnedev said in [New Plugin] ComparePlus v1.0.0:

                                            Try removing the quotes from compare - run it like that:
                                            –pluginMessage=compare

                                            So is this actually a bug in the ComparePlus plugin?
                                            (I don’t mean the -- part, which obviously should have just been -, I mean the lack of quotes)

                                            From the description in the N++ user manual HERE, I’d say a correct argument looks like this:

                                            -pluginMessage="compare filepath1 filepath2"

                                            (And of course, if either of the filepaths contains spaces, then my brain is starting to hurt, but…)

                                            Does it work without the double quotes because it must be used as the last argument on the N++ command line, and anything after -pluginMessage= is passed to the plugin and not looked at at all by N++?

                                            And how does N++ know that this specific one is meant for the ComparePlus plugin? Or does this same message get sent to all plugins? (that would strike me as “not a good thing”)

                                            pnedevP 1 Reply Last reply Reply Quote 0
                                            • First post
                                              Last post
                                            The Community of users of the Notepad++ text editor.
                                            Powered by NodeBB | Contributors