Loading ...
Sorry, an error occurred while loading the content.

Re: Scrolling (diffing) through VCS revisions

Expand Messages
  • Nikolay Pavlov
    ... version, not ... are for ... should ... off . I tried making this an issue on bitbucket but I got a 403. ... changes, they open a new buffer. ...
    Message 1 of 22 , Sep 30, 2013
    • 0 Attachment


      On Sep 30, 2013 6:21 PM, "Ben Fritz" <fritzophrenic@...> wrote:
      >
      > On Monday, September 30, 2013 5:13:45 AM UTC-5, ZyX wrote:
      > > On Sep 30, 2013 1:20 PM, "Paul" <googl...@...> wrote:
      > >
      > > >> Note: gJ and gK should be typed in the buffer with repository version, not
      > >
      > > >> in the buffer with version from current working directory. J and K are for
      > >
      > > >> just next/previous revision. If you are diffing two revisions they should
      > >
      > > >> work for both (in fact it is aurum://file mapping, not the
      > >
      > > >> AuVimDiff-specific one).
      > >
      > > >
      > >
      > > >
      > >
      > > > When I do gJ / gK, I get "E21: Cannot make changes, 'modifiable' is off". I tried making this an issue on bitbucket but I got a 403.
      > >
      > > Do you have any mappings to gJ/gK? These commands do not do any changes, they open a new buffer.
      > >
      > > : what does ":verbose nmap gJ" show?
      > >
      >
      > Hi, ZyX and Jan!
      >
      > I've encountered similar problems in the past, because I have a BufRead/BufWinEnter autocmd which sets 'nomodifiable' if 'readonly' is set. At one point I was doing a global "set nomodifiable" but now I do "setlocal" instead. Otherwise, any new buffers created also have 'nomodifiable' set.
      >
      > Jan, if you've got a similar autocmd, you should make the same fix.
      >
      > ZyX, if the new buffer your plugin is creating should always be modifiable, it would be smart to set 'modifiable' explicitly just in case it inherits a bad value.

      As I said, gJ does not modify current buffer: it instead opens a new one. 'nomodifiable' is set by aurum for all aurum://file buffers. Thus I assume he has similar problem with conflicting mappings as I have (I have remapped J for vim files though and not gJ, thus I am not much willing to resolve conflict).

      If what you mentioned here is the case he must be doing gJ in the wrong buffer (this must be done in the buffer with the committed version).

      > --
      > --
      > You received this message from the "vim_use" maillist.
      > Do not top-post! Type your reply below the text you are replying to.
      > For more information, visit http://www.vim.org/maillist.php
      >
      > ---
      > You received this message because you are subscribed to the Google Groups "vim_use" group.
      > To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@....
      > For more options, visit https://groups.google.com/groups/opt_out.

      --
      --
      You received this message from the "vim_use" maillist.
      Do not top-post! Type your reply below the text you are replying to.
      For more information, visit http://www.vim.org/maillist.php
       
      ---
      You received this message because you are subscribed to the Google Groups "vim_use" group.
      To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@....
      For more options, visit https://groups.google.com/groups/opt_out.
    • Ben Fritz
      ... And as I said, the new buffer may have nomodifiable set already, inherited from the global value of the option. gvim -N -u NONE -i NONE ... nomodifiable
      Message 2 of 22 , Sep 30, 2013
      • 0 Attachment
        On Monday, September 30, 2013 9:30:24 AM UTC-5, ZyX wrote:
        > On Sep 30, 2013 6:21 PM, "Ben Fritz" <fritzo...@...> wrote:
        > > ZyX, if the new buffer your plugin is creating should always be modifiable, it would be smart to set 'modifiable' explicitly just in case it inherits a bad value.
        >
        > As I said, gJ does not modify current buffer: it instead opens a new one.

        And as I said, the new buffer may have 'nomodifiable' set already, inherited from the global value of the option.

        gvim -N -u NONE -i NONE
        :set nomodifiable
        :new
        :set modifiable?
        nomodifiable

        --
        --
        You received this message from the "vim_use" maillist.
        Do not top-post! Type your reply below the text you are replying to.
        For more information, visit http://www.vim.org/maillist.php

        ---
        You received this message because you are subscribed to the Google Groups "vim_use" group.
        To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@....
        For more options, visit https://groups.google.com/groups/opt_out.
      • Nikolay Pavlov
        ... modifiable, it would be smart to set modifiable explicitly just in case it inherits a bad value. ... one. ... inherited from the global value of the
        Message 3 of 22 , Sep 30, 2013
        • 0 Attachment


          On Sep 30, 2013 7:06 PM, "Ben Fritz" <fritzophrenic@...> wrote:
          >
          > On Monday, September 30, 2013 9:30:24 AM UTC-5, ZyX wrote:
          > > On Sep 30, 2013 6:21 PM, "Ben Fritz" <fritzo...@...> wrote:
          > > > ZyX, if the new buffer your plugin is creating should always be modifiable, it would be smart to set 'modifiable' explicitly just in case it inherits a bad value.
          > >
          > > As I said, gJ does not modify current buffer: it instead opens a new one.
          >
          > And as I said, the new buffer may have 'nomodifiable' set already, inherited from the global value of the option.
          >
          > gvim -N -u NONE -i NONE
          > :set nomodifiable
          > :new
          > :set modifiable?
          >   nomodifiable

          This means buffer will be empty as it is populated with setline() (or some manipulations with vim.current.buffer in python). Who cares about not working gJ if buffer is empty while it should show committed version?

          Though I do not recall whether or not I was unsetting &modifiable. But this cannot lead to *just* not working gJ.

          > --
          > --
          > You received this message from the "vim_use" maillist.
          > Do not top-post! Type your reply below the text you are replying to.
          > For more information, visit http://www.vim.org/maillist.php
          >
          > ---
          > You received this message because you are subscribed to the Google Groups "vim_use" group.
          > To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@....
          > For more options, visit https://groups.google.com/groups/opt_out.

          --
          --
          You received this message from the "vim_use" maillist.
          Do not top-post! Type your reply below the text you are replying to.
          For more information, visit http://www.vim.org/maillist.php
           
          ---
          You received this message because you are subscribed to the Google Groups "vim_use" group.
          To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@....
          For more options, visit https://groups.google.com/groups/opt_out.
        • Paul
          ... I don t have any mention of modif in my ~/.vimrc, and I even disabled all other plugins. I didn t see a mention of modifiable in the output of :au
          Message 4 of 22 , Sep 30, 2013
          • 0 Attachment
            On Monday, 30 September, 2013 at 15:30:24 BST, Nikolay Pavlov wrote:
            >> I've encountered similar problems in the past, because I have a
            >BufRead/BufWinEnter autocmd which sets 'nomodifiable' if 'readonly' is set.
            >At one point I was doing a global "set nomodifiable" but now I do
            >"setlocal" instead. Otherwise, any new buffers created also have
            >'nomodifiable' set.
            >>
            >> Jan, if you've got a similar autocmd, you should make the same fix.

            I don't have any mention of 'modif' in my ~/.vimrc, and I even disabled all other plugins. I didn't see a mention of modifiable in the output of ':au BufRead' and ':au BufWinEnter'.

            There are no mappings for gJ / gK. There are maps for J and K, both set from frawor/mappings.vim.

            >If what you mentioned here is the case he must be doing gJ in the wrong
            >buffer (this must be done in the buffer with the committed version).

            I open a file, do ':AuVimDiff' on it. The version of the file in the repo opens in a new window. I switch to that new window, and it's there I do gJ / gK.

            --
            --
            You received this message from the "vim_use" maillist.
            Do not top-post! Type your reply below the text you are replying to.
            For more information, visit http://www.vim.org/maillist.php

            ---
            You received this message because you are subscribed to the Google Groups "vim_use" group.
            To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@....
            For more options, visit https://groups.google.com/groups/opt_out.
          • Nikolay Pavlov
            ... set. ... all other plugins. I didn t see a mention of modifiable in the output of :au BufRead and :au BufWinEnter . ... from frawor/mappings.vim. What
            Message 5 of 22 , Sep 30, 2013
            • 0 Attachment


              On Sep 30, 2013 8:56 PM, "Paul" <google1241@...> wrote:
              >
              > On Monday, 30 September, 2013 at 15:30:24 BST, Nikolay Pavlov wrote:
              >>>
              >>> I've encountered similar problems in the past, because I have a
              >>
              >> BufRead/BufWinEnter autocmd which sets 'nomodifiable' if 'readonly' is set.
              >> At one point I was doing a global "set nomodifiable" but now I do
              >> "setlocal" instead. Otherwise, any new buffers created also have
              >> 'nomodifiable' set.
              >>>
              >>>
              >>> Jan, if you've got a similar autocmd, you should make the same fix.
              >
              >
              > I don't have any mention of 'modif' in my ~/.vimrc, and I even disabled all other plugins. I didn't see a mention of modifiable in the output of ':au BufRead' and ':au BufWinEnter'.
              >
              > There are no mappings for gJ / gK. There are maps for J and K, both set from frawor/mappings.vim.

              What version of aurum do you use? Just found out that I not have this functionality in release: it was added in https://bitbucket.org/ZyX_I/aurum/commits/49b075fb190379a76e2d55f86309e9a15c664d1f (nearly two weeks after last release).

              >
              >> If what you mentioned here is the case he must be doing gJ in the wrong
              >> buffer (this must be done in the buffer with the committed version).
              >
              >
              > I open a file, do ':AuVimDiff' on it. The version of the file in the repo opens in a new window. I switch to that new window, and it's there I do gJ / gK.
              >
              >
              > --
              > --
              > You received this message from the "vim_use" maillist.
              > Do not top-post! Type your reply below the text you are replying to.
              > For more information, visit http://www.vim.org/maillist.php
              >
              > --- You received this message because you are subscribed to the Google Groups "vim_use" group.
              > To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@....
              > For more options, visit https://groups.google.com/groups/opt_out.

              --
              --
              You received this message from the "vim_use" maillist.
              Do not top-post! Type your reply below the text you are replying to.
              For more information, visit http://www.vim.org/maillist.php
               
              ---
              You received this message because you are subscribed to the Google Groups "vim_use" group.
              To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@....
              For more options, visit https://groups.google.com/groups/opt_out.
            • Paul
              ... I was using 1.7.1 from http://www.vim.org/scripts/script.php?script_id=3828, but I just tried the latest from bitbucket, and while I don t get that E error
              Message 6 of 22 , Oct 1, 2013
              • 0 Attachment
                On Monday, 30 September, 2013 at 18:03:41 BST, Nikolay Pavlov wrote:
                >What version of aurum do you use? Just found out that I not have this
                >functionality in release: it was added in
                >https://bitbucket.org/ZyX_I/aurum/commits/49b075fb190379a76e2d55f86309e9a15c664d1f(nearly
                >two weeks after last release).

                I was using 1.7.1 from http://www.vim.org/scripts/script.php?script_id=3828, but I just tried the latest from bitbucket, and while I don't get that E error any more, and gJ / gK appear to be going through the correct revisions for the file (according to the filename at the bottom, which includes the commit number), the window just isn't showing the differences for each revision, like it's not always being updated. I'll investigate it more later.

                --
                --
                You received this message from the "vim_use" maillist.
                Do not top-post! Type your reply below the text you are replying to.
                For more information, visit http://www.vim.org/maillist.php

                ---
                You received this message because you are subscribed to the Google Groups "vim_use" group.
                To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@....
                For more options, visit https://groups.google.com/groups/opt_out.
              • ZyX
                ... You are lucky that it iterates correctly for subversion. I see the correct behavior for the VCS systems I use (mercurial and git), failing tests for
                Message 7 of 22 , Oct 1, 2013
                • 0 Attachment
                  > I was using 1.7.1 from http://www.vim.org/scripts/script.php?script_id=3828, but I just tried the latest from bitbucket, and while I don't get that E error any more, and gJ / gK appear to be going through the correct revisions for the file (according to the filename at the bottom, which includes the commit number), the window just isn't showing the differences for each revision, like it's not always being updated. I'll investigate it more later.

                  You are lucky that it iterates correctly for subversion. I see the correct behavior for the VCS systems I use (mercurial and git), failing tests for subversion-1.7.13 (they did work for subversion-1.6*) and surprisingly inconsistent behavior between gJ and :AuStatus: while gJ works like J (skip to next revision) on test lh-vim-lib repository, :AuStatus shows that test file was not changed in the revision gJ brought me to. It is surprising because :AuS and gJ use the same driver function.

                  I will investigate these issues in the weekend for sure and maybe earlier. Until the time subversion driver should be considered broken. The downside of “but its subversion and bazaar backends are least stable as the only place where I use both VCSes is aurum test suite”.

                  --
                  --
                  You received this message from the "vim_use" maillist.
                  Do not top-post! Type your reply below the text you are replying to.
                  For more information, visit http://www.vim.org/maillist.php

                  ---
                  You received this message because you are subscribed to the Google Groups "vim_use" group.
                  To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@....
                  For more options, visit https://groups.google.com/groups/opt_out.
                • Paul
                  ... FYI, I m trying 1.8 and gK does exactly what gJ does, ie. it doesn t go forward in time, keeps going back. I can see that the mapping for it is indeed
                  Message 8 of 22 , Oct 10, 2013
                  • 0 Attachment
                    On Tuesday, 01 October, 2013 at 19:38:38 BST, ZyX wrote:
                    >I will investigate these issues in the weekend for sure and maybe earlier. Until the time subversion driver should be considered broken. The downside of “but its subversion and bazaar backends are least stable as the only place where I use both VCSes is aurum test suite”.

                    FYI, I'm trying 1.8 and gK does exactly what gJ does, ie. it doesn't go forward in time, keeps going back. I can see that the mapping for it is indeed different to that of gK, calling 'next' instead of 'previous'.

                    --
                    --
                    You received this message from the "vim_use" maillist.
                    Do not top-post! Type your reply below the text you are replying to.
                    For more information, visit http://www.vim.org/maillist.php

                    ---
                    You received this message because you are subscribed to the Google Groups "vim_use" group.
                    To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@....
                    For more options, visit https://groups.google.com/groups/opt_out.
                  • Nikolay Pavlov
                    ... earlier. Until the time subversion driver should be considered broken. The downside of ôbut its subversion and bazaar backends are least stable as the
                    Message 9 of 22 , Oct 10, 2013
                    • 0 Attachment


                      On Oct 11, 2013 2:55 AM, "Paul" <google1241@...> wrote:
                      >
                      > On Tuesday, 01 October, 2013 at 19:38:38 BST, ZyX wrote:
                      >>
                      >> I will investigate these issues in the weekend for sure and maybe earlier. Until the time subversion driver should be considered broken. The downside of “but its subversion and bazaar backends are least stable as the only place where I use both VCSes is aurum test suite”.
                      >
                      >
                      > FYI, I'm trying 1.8 and gK does exactly what gJ does, ie. it doesn't go forward in time, keeps going back. I can see that the mapping for it is indeed different to that of gK, calling 'next' instead of 'previous'.

                      Fixed in 1.8.1. Thanks for the report.

                      > --
                      > --
                      > You received this message from the "vim_use" maillist.
                      > Do not top-post! Type your reply below the text you are replying to.
                      > For more information, visit http://www.vim.org/maillist.php
                      >
                      > --- You received this message because you are subscribed to the Google Groups "vim_use" group.
                      > To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@....
                      > For more options, visit https://groups.google.com/groups/opt_out.

                      --
                      --
                      You received this message from the "vim_use" maillist.
                      Do not top-post! Type your reply below the text you are replying to.
                      For more information, visit http://www.vim.org/maillist.php
                       
                      ---
                      You received this message because you are subscribed to the Google Groups "vim_use" group.
                      To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@....
                      For more options, visit https://groups.google.com/groups/opt_out.
                    • Paul
                      ... I m still seeing that behaviour in 1.8.1à -- -- You received this message from the vim_use maillist. Do not top-post! Type your reply below the text you
                      Message 10 of 22 , Oct 11, 2013
                      • 0 Attachment
                        On Friday, 11 October, 2013 at 04:30:32 BST, Nikolay Pavlov wrote:
                        >> FYI, I'm trying 1.8 and gK does exactly what gJ does, ie. it doesn't go
                        >forward in time, keeps going back. I can see that the mapping for it is
                        >indeed different to that of gK, calling 'next' instead of 'previous'.
                        >
                        >Fixed in 1.8.1. Thanks for the report.

                        I'm still seeing that behaviour in 1.8.1…

                        --
                        --
                        You received this message from the "vim_use" maillist.
                        Do not top-post! Type your reply below the text you are replying to.
                        For more information, visit http://www.vim.org/maillist.php

                        ---
                        You received this message because you are subscribed to the Google Groups "vim_use" group.
                        To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@....
                        For more options, visit https://groups.google.com/groups/opt_out.
                      • ZyX
                        ... Sorry, fix was committed to a wrong branch. It should be fine now. -- -- You received this message from the vim_use maillist. Do not top-post! Type your
                        Message 11 of 22 , Oct 11, 2013
                        • 0 Attachment
                          > I'm still seeing that behaviour in 1.8.1…

                          Sorry, fix was committed to a wrong branch. It should be fine now.

                          --
                          --
                          You received this message from the "vim_use" maillist.
                          Do not top-post! Type your reply below the text you are replying to.
                          For more information, visit http://www.vim.org/maillist.php

                          ---
                          You received this message because you are subscribed to the Google Groups "vim_use" group.
                          To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@....
                          For more options, visit https://groups.google.com/groups/opt_out.
                        Your message has been successfully submitted and would be delivered to recipients shortly.