In addition is there any universal way of doing this which works for other types of projects (in other perspectives) as well?
Package Explorer > View menu (the triangle) > Configure Working Sets... There you can configure the ordering or choose auto-sorting.
There is a Sort menu when you click on the arrow on the top left of the view, you can select sort by name or sort by type.
But you can group Projects into named Working Sets. On the Package Explorer or Project Explorer view menu, you can use Top Level Elements -> Working Sets and use Configure Working Sets.../Select Working Sets... to organize your Projects into folder-like groups.
To switch to PyDev, if it isn't already selected, choose Window > Perspective > Open Perspective > Other > PyDev. Then, select the PyDev Package Explorer view by choosing Window > Show View > PyDev Package Explorer to see and access the contents of each project directory.
I was experiencing this (very annoying) problem, and I found a post by somebody on SourceForge having the same problem who said he discovered that if he added the project's root folder to its PYTHONPATH, it cleared up the problem. So I looked at my mis-alphabetized project's PYTHONPATH and saw that it already included the root folder in addition to the src folder. So just on a whim, I removed the root folder from PYTHONPATH. (I really should not have had it there anyway.) And although that was the opposite of what he said fixed his problem, it fixed my problem. Go figure.
The following worked for me:
The problem projects then magically appeared in the right order.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With