Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Custom Sort Order in File Explorer #119207

Closed
KyleMit opened this issue Mar 17, 2021 · 1 comment
Closed

Custom Sort Order in File Explorer #119207

KyleMit opened this issue Mar 17, 2021 · 1 comment
Assignees
Labels
*duplicate Issue identified as a duplicate of another issue(s) file-explorer Explorer widget issues

Comments

@KyleMit
Copy link
Contributor

KyleMit commented Mar 17, 2021

I'd like to specify a custom sort order in the file explorer. For example sorting folders like this:


components
├── layout
├── ui
├── utils
├── other-folder
└── another-folder

Where the bold folders have an an explicit sort order specified, and then everything else is sorted alphabetically.

Currently, there's a setting for explorer.sortOrder which takes in default | mixed | filesFirst | type | modified, but doesn't allow explicit lists.

API Proposal 1

sortOrder could potentially be extended to take a value of custom with an additional array passed in like this:

{
  "explorer.sortOrder": "custom",
  "explorer.sortCustom": ["layout", "ui", "utils"]
}

API Proposal 2

Another place this shows up in when cloning a wiki project in Azure Dev Ops, which specifies an .order file that provides a custom sort order on their UI

eg. .order

Welcome
Home
Boards
More Articles

Extension

If there's a way to accomplish this with an extension, I'd be willing to take a pass at it if folks have any ideas about where to start or if it's possible

Workaround

You could rename folders, 1 - layout, 2- ui, 3-utils, but this approach is much noisier

Further Reading

@isidorn
Copy link
Contributor

isidorn commented Mar 18, 2021

Makes sense, however closing as dup of #27286

@isidorn isidorn closed this as completed Mar 18, 2021
@isidorn isidorn added *duplicate Issue identified as a duplicate of another issue(s) file-explorer Explorer widget issues labels Mar 18, 2021
@github-actions github-actions bot locked and limited conversation to collaborators May 2, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
*duplicate Issue identified as a duplicate of another issue(s) file-explorer Explorer widget issues
Projects
None yet
Development

No branches or pull requests

2 participants