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

Vim persistent undo with sudoedit

Expand Messages
  • rprabhu@wnohang.net
    Hi, I use persistent undo feature of vim. However, I use sudoedit when editing files as root. This breaks the persistent undo since it relies on filenames. Is
    Message 1 of 5 , Jan 2, 2012
    • 0 Attachment
      Hi,

      I use persistent undo feature of vim. However, I use sudoedit
      when editing files as root. This breaks the persistent undo since
      it relies on filenames. Is there a way around this ? I tried a
      few vim plugins (like sudo.vim) which didn't seem to work for me.
      I am using either of them because a few plugins (like
      neocomplcache) complain that they won't run as sudo (which is
      right) since they run a few things in background. So is there a
      way around this ?

      --------------------------
      Raghavendra Prabhu
      GPG Id : 0xD72BE977
      Fingerprint: B93F EBCB 8E05 7039 CD3C A4B8 A616 DCA1 D72B E977
      www: wnohang.net
    • Gary Johnson
      ... Did you try the latest version of SudoEdit.vim (http://vim.sourceforge.net/scripts/script.php?script_id=2709)? The release notes for version 11 mention
      Message 2 of 5 , Jan 2, 2012
      • 0 Attachment
        On 2012-01-03, Raghavendra Prabhu wrote:
        > Hi,
        >
        > I use persistent undo feature of vim. However, I use sudoedit when
        > editing files as root. This breaks the persistent undo since it
        > relies on filenames. Is there a way around this ? I tried a few vim
        > plugins (like sudo.vim) which didn't seem to work for me.
        > I am using either of them because a few plugins (like neocomplcache)
        > complain that they won't run as sudo (which is right) since they run
        > a few things in background. So is there a way around this ?

        Did you try the latest version of SudoEdit.vim
        (http://vim.sourceforge.net/scripts/script.php?script_id=2709)? The
        release notes for version 11 mention fixing a problem with the undo
        file, so it appears that it is supposed to work with persistent
        undo.

        Regards,
        Gary

        --
        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
      • Christian Brabandt
        Hi rprabhu! ... Try the SudoEdit¹ plugin. That implements a workaround. But be sure to at least use a vim 7.3.367
        Message 3 of 5 , Jan 2, 2012
        • 0 Attachment
          Hi rprabhu!

          On Di, 03 Jan 2012, rprabhu@... wrote:

          > Hi,
          >
          > I use persistent undo feature of vim. However, I use sudoedit when
          > editing files as root. This breaks the persistent undo since it
          > relies on filenames. Is there a way around this ? I tried a few vim
          > plugins (like sudo.vim) which didn't seem to work for me.
          > I am using either of them because a few plugins (like neocomplcache)
          > complain that they won't run as sudo (which is right) since they
          > run a few things in background. So is there a way around this ?

          Try the SudoEditน plugin. That implements a workaround. But be sure to
          at least use a vim > 7.3.367

          น)http://www.vim.org/scripts/script.php?script_id=2709

          regards,
          Christian
          --

          --
          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
        • rprabhu@wnohang.net
          ... Hi, I had tried SudoEdit (after sudo.vim) some time back and not used it for one of the reasons. Now it is working fine. :) Thanks. Raghavendra
          Message 4 of 5 , Jan 2, 2012
          • 0 Attachment
            * On Mon, Jan 02, 2012 at 10:43:45PM +0100, Christian Brabandt <cblists@...> wrote:
            >Hi rprabhu!
            >
            >On Di, 03 Jan 2012, rprabhu@... wrote:
            >
            >> Hi,

            >> I use persistent undo feature of vim. However, I use sudoedit when
            >> editing files as root. This breaks the persistent undo since it
            >> relies on filenames. Is there a way around this ? I tried a few vim
            >> plugins (like sudo.vim) which didn't seem to work for me.
            >> I am using either of them because a few plugins (like neocomplcache)
            >> complain that they won't run as sudo (which is right) since they
            >> run a few things in background. So is there a way around this ?
            >
            >Try the SudoEditน plugin. That implements a workaround. But be sure to
            >at least use a vim > 7.3.367
            >
            >น)http://www.vim.org/scripts/script.php?script_id=2709
            >
            >regards,
            >Christian


            Hi,

            I had tried SudoEdit (after sudo.vim) some time back and not used it for one of
            the reasons. Now it is working fine. :)

            Thanks.
            Raghavendra
          • Christian Brabandt
            Hi rprabhu! ... You really should give feedback to the author of a plugin, if you notice a problem with it. regards, Christian -- -- You received this message
            Message 5 of 5 , Jan 2, 2012
            • 0 Attachment
              Hi rprabhu!

              On Di, 03 Jan 2012, rprabhu@... wrote:

              > * On Mon, Jan 02, 2012 at 10:43:45PM +0100, Christian Brabandt <cblists@...> wrote:
              > >Hi rprabhu!
              > >
              > >On Di, 03 Jan 2012, rprabhu@... wrote:
              > >
              > >>Hi,
              >
              > >>I use persistent undo feature of vim. However, I use sudoedit when
              > >>editing files as root. This breaks the persistent undo since it
              > >>relies on filenames. Is there a way around this ? I tried a few vim
              > >>plugins (like sudo.vim) which didn't seem to work for me.
              > >>I am using either of them because a few plugins (like neocomplcache)
              > >>complain that they won't run as sudo (which is right) since they
              > >>run a few things in background. So is there a way around this ?
              > >
              > >Try the SudoEditน plugin. That implements a workaround. But be sure to
              > >at least use a vim > 7.3.367
              > >
              > >น)http://www.vim.org/scripts/script.php?script_id=2709
              > >
              > >regards,
              > >Christian
              >
              >
              > Hi,
              >
              > I had tried SudoEdit (after sudo.vim) some time back and not used it
              > for one of the reasons. Now it is working fine. :)

              You really should give feedback to the author of a plugin, if you notice
              a problem with it.


              regards,
              Christian
              --

              --
              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
            Your message has been successfully submitted and would be delivered to recipients shortly.