Community

    • Login
    • Search
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search

    sorting in folder as workspace

    Help wanted · · · – – – · · ·
    2
    8
    429
    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.
    • James Trenton
      James Trenton last edited by

      Hi,

      I have two different versions of Notepad++ that I’m using:

      1. Version 8.4.2 (64 bit) installed to C:\Program Files\Notepad++.

      2. Version 8.4.2 (64 bit) Portable located on a USB drive.

      I use “folder as workspace” to view my files.

      When I am running on the full-install version of Notepad++ (on my C: drive) and viewing folder as workspace, the files and folders are sorted and appear correctly.

      When I’m running the portable version of Notepad++ (on my USB drive) and viewing folder as workspace (with files located on my USB drive), they are not sorted by alphabetical order.

      TL;DR -

      Installed version sorts folder as workspace correctly while portable version does not.

      Any suggestions for how to fix this?

      faw-local.png faw-portable.png

      PeterJones 1 Reply Last reply Reply Quote 0
      • PeterJones
        PeterJones @James Trenton last edited by PeterJones

        @James-Trenton ,

        What happens if you use the installed Notepad++ instance to open the USB’s garden\ folder as a workspace? (Because if it is sorted on the local garden but not sorted on the USB garden, with the same installed copy of Notepad++, then it’s something to do with the filesystem on the USB stick, not with installed-vs-portable)

        I don’t think that the Folder as Workspace feature currently has sorting capability, so you might want to read the FAQ on how to make a feature request if that’s a feature you’d want

        Addenda: For example, I just created a new garden folder and created apple, carrot, and banana subfolders (in that order) on my drive. Then I opened the garden folder as Workspace in both installed and portable copy, and they both showed them as
        302d94a5-8bda-40ba-9159-48736025eeef-image.png
        (My work machines prohibit USB drives, so I cannot test on a USB garden right now.)

        James Trenton 1 Reply Last reply Reply Quote 1
        • James Trenton
          James Trenton @PeterJones last edited by

          @PeterJones

          To answer your question — if I use the installed version of Notepad++ (from C: drive ) to view the USB directory files via “folder as workspace” – it appears unsorted.

          It’s not a major problem. I just thought that maybe there was some easy “sort” option that I was missing. But, if the app doesn’t do any sorting then it must be OS or USB related.

          I am doing a “trick” on my USB drive to allow for relative paths and changing drive letters.

          (Set shortcut target to: %windir%\explorer.exe “Dev\npp.8.4.2.portable.x64\notepad++.exe”)

          But, to eliminate this as a cause of the problem, I launched the app directly by clicking on the executable directly (avoiding the shortcut):

          D:\Dev\npp.8.4.2.portable.x64\notepad++.exe

          I had the same problem (folders/files are not appearing in alpha order).

          It is only an issue when I’m running the Portable version of Notepad++.

          I appreciate your help.

          PeterJones 1 Reply Last reply Reply Quote 0
          • James Trenton
            James Trenton last edited by

            UPDATE:

            I checked again. It is sorting by alpha order (but, it is descending, instead of ascending).

            1 Reply Last reply Reply Quote 0
            • PeterJones
              PeterJones @James Trenton last edited by

              @James-Trenton

              if I use the installed version of Notepad++ (from C: drive ) to view the USB directory files via “folder as workspace” – it appears unsorted.

              vs

              It is only an issue when I’m running the Portable version of Notepad++.

              You just contradicted yourself. If you run the installed Notepad++ and the FolderAsWorkspace of USB\garden is not sorted (or rather, reverse sorted), and run portable Notepad++ and FolderAsWorkspace of USB\garden is also unsorted (or rather, reverse sorted), which is what you’ve told us, then the problem is not with “portable” vs “installed”, because they act the same.

              The problem appears to be that on the USB stick, when Notepad++ asks for a directory listing, the OS gives it unsorted (or reverse sorted), whereas when you FaW on your c:\ drive, the OS tells Notepad++ the list in alphabetical sorted.

              So, as I said, the problem is the difference between c:\ and USB for the FaW, not the difference between portable and installed notepad++. Unless I have misinterpreted what you’ve told us.

              James Trenton 1 Reply Last reply Reply Quote 1
              • James Trenton
                James Trenton @PeterJones last edited by James Trenton

                @PeterJones said in sorting in folder as workspace:

                You just contradicted yourself.

                Sorry, I’m not trying to be confusing. I’m not describing my issue very clearly. Here are my test cases thus far:

                1. Running locally, viewing local files:
                • launch “C:\Program Files\Notepad++\notepad++.exe”

                • add C:\test directory to workspace. File sorting appears correctly (ascending alpha order).

                1. Running Portable from USB drive, viewing USB files:
                • launch “D:\Dev\npp.8.4.2.portable.x64notepad++.exe”

                • add D:\test to workspace. File sorting appears correctly (ascending alpha order).

                • add D:\Dev\servers\UniServerZ\www to workspace. File sorting does NOT appear correctly. (descending alpha order).

                So, it seems to be directory-related. If I store the files in the root level at D:\test the sorting appears correct. But, if I choose a directory 4 levels deep, the sorting is in reverse order.

                This is an older Win 7 (64 bit) machine.

                I appreciate your help. I have learned some new info by researching this. Hopefully, I will be able to clarify the behavior more succinctly? Maybe it’s just a case of a Windows 7 bug?

                I’ll keep investigating.

                PeterJones 1 Reply Last reply Reply Quote 0
                • PeterJones
                  PeterJones @James Trenton last edited by

                  @James-Trenton ,

                  As a reminder, Windows 7 is no longer supported by Notepad++, though it may still be able to run it.

                  From what I know of USB filesystems, their sorting is much more “hardcoded” than a modern hard drive (HDD) or solid state drive (SSD). Windows OS may choose to present the contents of a USB in a different order than it would present the contents of a similar folder structure on a HDD/SSD. I think your problem is OS and filesystem related.

                  James Trenton 1 Reply Last reply Reply Quote 1
                  • James Trenton
                    James Trenton @PeterJones last edited by

                    @PeterJones

                    Yes, I believe you are correct. Thanks for helping me to troubleshoot this. I will try on a newer version of Windows and see if I have any more issues.

                    Thanks for your help. Much appreciated.

                    1 Reply Last reply Reply Quote 0
                    • First post
                      Last post
                    Copyright © 2014 NodeBB Forums | Contributors