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

Problem with opening files and directories on the command line

Expand Messages
  • Dennis Benzinger
    Hi! If I try to open a directory and some files on the command line by using vim -o dir file1 file2 I get three split windows with the following buffer names
    Message 1 of 7 , May 5, 2010
    • 0 Attachment
      Hi!

      If I try to open a directory and some files on the command line by using

      vim -o dir file1 file2

      I get three split windows with the following buffer names in their
      statusline: NetrwTreeListing 1, dir, dir
      The topmost windows shows the contents of the current directory in netrw.
      But it only shows the directory dir, not the two files.
      The other two windows are empty. When I move the cursor to the empty windows
      (Ctrl-W j) they start to show the same strange netrw listing with the files
      missing. The buffer names in the status line then change to
      NetrwTreeListing 2 and NetrwTreeListing 3.

      I'm using Vim 7.2.411 and the netrw windows show v136.

      Can anyone reproduce this or is it a problem with my configuration?


      Regards,
      Dennis Benzinger

      --
      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
    • Gary Johnson
      ... I see the same thing. I was about to report that it worked for me because I tried it with this command line: vim -N -u NONE --cmd runtime
      Message 2 of 7 , May 5, 2010
      • 0 Attachment
        On 2010-05-05, Dennis Benzinger wrote:
        > Hi!
        >
        > If I try to open a directory and some files on the command line by using
        >
        > vim -o dir file1 file2
        >
        > I get three split windows with the following buffer names in their
        > statusline: NetrwTreeListing 1, dir, dir
        > The topmost windows shows the contents of the current directory in netrw.
        > But it only shows the directory dir, not the two files.
        > The other two windows are empty. When I move the cursor to the empty windows
        > (Ctrl-W j) they start to show the same strange netrw listing with the files
        > missing. The buffer names in the status line then change to
        > NetrwTreeListing 2 and NetrwTreeListing 3.
        >
        > I'm using Vim 7.2.411 and the netrw windows show v136.
        >
        > Can anyone reproduce this or is it a problem with my configuration?

        I see the same thing. I was about to report that it worked for me
        because I tried it with this command line:

        vim -N -u NONE --cmd 'runtime plugin/netrwPlugin.vim' -o . foo.m foobar.vim

        and with that command it does work fine. But then I realized that I
        wasn't faithfully reproducing your example, so I changed the
        directory from "." to "tmp":

        vim -N -u NONE --cmd 'runtime plugin/netrwPlugin.vim' -o tmp foo.m foobar.vim

        That command fails for me almost the same way it did for you: the
        top window contains the directory contents and has the name
        "[Scratch] [RO]"; the other two windows are empty and have the name
        "tmp".

        The cursor starts in the top window. When I type ^W^W to move to
        the second window, the second window fills with the same directory
        contents and the name in the status line changes to "[Scratch]
        [RO]". Typing ^W^W again moves the cursor to the bottom window
        which again fills with the directory contents, but this time the
        name in the status line becomes the name of the directory,
        "/home/garyjohn/tmp [RO]".

        I'm using Vim 7.2.411 and netrw v137d on RHEL4.

        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
      • Charles Campbell
        ... Hello! I ll look into it. Regards, Chip Campbell -- You received this message from the vim_use maillist. Do not top-post! Type your reply below the text
        Message 3 of 7 , May 5, 2010
        • 0 Attachment
          Dennis Benzinger wrote:
          > Hi!
          >
          > If I try to open a directory and some files on the command line by using
          >
          > vim -o dir file1 file2
          >
          > I get three split windows with the following buffer names in their
          > statusline: NetrwTreeListing 1, dir, dir
          >

          Hello!

          I'll look into it.

          Regards,
          Chip Campbell

          --
          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
        • Charles Campbell
          ... Hello! Please try netrw v138b, available at my website as http://mysite.verizon.net/astronaut/vim/index.html#NETRW . Regards, Chip Campbell -- You received
          Message 4 of 7 , May 7, 2010
          • 0 Attachment
            Dennis Benzinger wrote:
            > Hi!
            >
            > If I try to open a directory and some files on the command line by using
            >
            > vim -o dir file1 file2
            >
            > I get three split windows with the following buffer names in their
            > statusline: NetrwTreeListing 1, dir, dir
            > The topmost windows shows the contents of the current directory in netrw.
            > But it only shows the directory dir, not the two files.
            > The other two windows are empty. When I move the cursor to the empty windows
            > (Ctrl-W j) they start to show the same strange netrw listing with the files
            > missing. The buffer names in the status line then change to
            > NetrwTreeListing 2 and NetrwTreeListing 3.
            >
            > I'm using Vim 7.2.411 and the netrw windows show v136.
            >
            > Can anyone reproduce this or is it a problem with my configuration?
            >

            Hello!

            Please try netrw v138b, available at my website as
            http://mysite.verizon.net/astronaut/vim/index.html#NETRW .

            Regards,
            Chip Campbell

            --
            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
          • Dennis Benzinger
            Hello Mr. Campbell! ... Thanks for the new version. It almost works. Normally I have let g:netrw_liststyle = 3 in my .vimrc. With this setting three netrw
            Message 5 of 7 , May 8, 2010
            • 0 Attachment
              Hello Mr. Campbell!

              Am 07.05.2010 23:02, schrieb Charles Campbell:
              > Dennis Benzinger wrote:
              >> Hi!
              >>
              >> If I try to open a directory and some files on the command line by using
              >>
              >> vim -o dir file1 file2
              >>
              >> I get three split windows with the following buffer names in their
              >> statusline: NetrwTreeListing 1, dir, dir
              >> The topmost windows shows the contents of the current directory in netrw.
              >> But it only shows the directory dir, not the two files.
              >> The other two windows are empty. When I move the cursor to the empty
              >> windows
              >> (Ctrl-W j) they start to show the same strange netrw listing with the
              >> files
              >> missing. The buffer names in the status line then change to
              >> NetrwTreeListing 2 and NetrwTreeListing 3.
              >>
              >> I'm using Vim 7.2.411 and the netrw windows show v136.
              >>
              >> Can anyone reproduce this or is it a problem with my configuration?
              >
              > Hello!
              >
              > Please try netrw v138b, available at my website as
              > http://mysite.verizon.net/astronaut/vim/index.html#NETRW .
              >[...]

              Thanks for the new version. It almost works. Normally I have

              let g:netrw_liststyle = 3

              in my .vimrc. With this setting three netrw windows are shown. In these
              windows the two files are missing and only the subdirectory is shown.
              If I remove this setting or use the styles zero to two it works.


              Regards,
              Dennis Benzinger

              --
              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
            • Charles Campbell
              ... Hello, Dennis: I m sorry its been such an inordinate long time, but I in looking at my old email I saw that the problem you d mentioned was still
              Message 6 of 7 , Apr 29, 2013
              • 0 Attachment
                Dennis Benzinger wrote:
                > Hello Mr. Campbell!
                >
                > Am 07.05.2010 23:02, schrieb Charles Campbell:
                >> Dennis Benzinger wrote:
                >>> Hi!
                >>>
                >>> If I try to open a directory and some files on the command line by
                >>> using
                >>>
                >>> vim -o dir file1 file2
                >>>
                >>> I get three split windows with the following buffer names in their
                >>> statusline: NetrwTreeListing 1, dir, dir
                >>> The topmost windows shows the contents of the current directory in
                >>> netrw.
                >>> But it only shows the directory dir, not the two files.
                >>> The other two windows are empty. When I move the cursor to the empty
                >>> windows
                >>> (Ctrl-W j) they start to show the same strange netrw listing with the
                >>> files
                >>> missing. The buffer names in the status line then change to
                >>> NetrwTreeListing 2 and NetrwTreeListing 3.
                >>>
                >>> I'm using Vim 7.2.411 and the netrw windows show v136.
                >>>
                >>> Can anyone reproduce this or is it a problem with my configuration?
                >>
                >> Hello!
                >>
                >> Please try netrw v138b, available at my website as
                >> http://mysite.verizon.net/astronaut/vim/index.html#NETRW .
                >> [...]
                >
                > Thanks for the new version. It almost works. Normally I have
                >
                > let g:netrw_liststyle = 3
                >
                > in my .vimrc. With this setting three netrw windows are shown. In
                > these windows the two files are missing and only the subdirectory is
                > shown.
                > If I remove this setting or use the styles zero to two it works.
                Hello, Dennis:

                I'm sorry its been such an inordinate long time, but I in looking at my
                old email I saw that the problem you'd mentioned was still outstanding
                -- and still present. Part of the problem was that it was weird that
                tree listing mode would have the effect it did. Anyway, I'm hoping that
                the current netrw (v149c) addresses the issues you'd found.

                You can get a copy from my website:
                http://www.drchip.org/astronaut/vim/index.html#NETRW .

                Regards,
                Chip Campbell

                --
                --
                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.
              • Dominique PellĂ©
                ... Hi Charles I just downloaded netrw v149c. I still see what looks like a bug and which I reported earlier. Please review this patch: $ diff -c
                Message 7 of 7 , Apr 29, 2013
                • 0 Attachment
                  Charles Campbell wrote:

                  > Hello, Dennis:
                  >
                  > I'm sorry its been such an inordinate long time, but I in looking at my old
                  > email I saw that the problem you'd mentioned was still outstanding -- and
                  > still present. Part of the problem was that it was weird that tree listing
                  > mode would have the effect it did. Anyway, I'm hoping that the current netrw
                  > (v149c) addresses the issues you'd found.
                  >
                  > You can get a copy from my website:
                  > http://www.drchip.org/astronaut/vim/index.html#NETRW .

                  Hi Charles

                  I just downloaded netrw v149c. I still see what looks like
                  a bug and which I reported earlier. Please review this patch:

                  $ diff -c autoload/netrw.vim.orig autoload/netrw.vim
                  *** autoload/netrw.vim.orig 2013-04-29 23:01:56.987914815 +0200
                  --- autoload/netrw.vim 2013-04-29 23:02:12.195914685 +0200
                  ***************
                  *** 4193,4199 ****
                  let b:netrw_curdir= getcwd().'/'.prefixdir
                  endif
                  let dirname= substitute(dirname,'^.\{-}\(\*\*/.*\)$','\1','')
                  ! let starpat= 4;
                  " call Decho("(Explore) ..pwd<".getcwd()."> dirname<".dirname.">")
                  " call Decho("(Explore) ..case Explore ../**/../filepat
                  (starpat=".starpat.")")

                  --- 4193,4199 ----
                  let b:netrw_curdir= getcwd().'/'.prefixdir
                  endif
                  let dirname= substitute(dirname,'^.\{-}\(\*\*/.*\)$','\1','')
                  ! let starpat= 4
                  " call Decho("(Explore) ..pwd<".getcwd()."> dirname<".dirname.">")
                  " call Decho("(Explore) ..case Explore ../**/../filepat
                  (starpat=".starpat.")")

                  Regards
                  Dominique

                  --
                  --
                  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.