sort directories WITH files
Moderators: Hacker, petermad, Stefan2, white
sort directories WITH files
We know that directories are normally listed BEFORE files. All the directories "<DIR>" are bunched together at the top of the panel. QUESTION: Is there an option to sort directories WITH files?
That would be useful when I want to delete or move old web pages that I had saved as html. The saved item has two parts "foo.html" and "foo_files/". Seeing them displayed together would remind me to manage both items.
The sorted order would be: foo_files\; foo.html; goof\
rather than the normal: foo_files\; goof\; foo.html
This may not be worth implementing. One workaround is to type control-s and then "foo"
That would be useful when I want to delete or move old web pages that I had saved as html. The saved item has two parts "foo.html" and "foo_files/". Seeing them displayed together would remind me to manage both items.
The sorted order would be: foo_files\; foo.html; goof\
rather than the normal: foo_files\; goof\; foo.html
This may not be worth implementing. One workaround is to type control-s and then "foo"
Re: sort directories WITH files
Just delete foo.html and foo_files should automatically be deleted as well (so no need to select both file & folder in this case).nn1k3 wrote: 2025-02-07, 19:17 UTCThat would be useful when I want to delete or move old web pages that I had saved as html. The saved item has two parts "foo.html" and "foo_files/".
F4MiniMenu (Forum) - Open selected file(s) from TC in defined editor(s) - A (minimalistic) clone of F4Menu
Source at GitHub (AutoHotkey). TCSyncComments (copy file comments)
Source at GitHub (AutoHotkey). TCSyncComments (copy file comments)
Re: sort directories WITH files
This works this way only if the explorer delete method is enabled!hi5 wrote: 2025-02-07, 20:22 UTC Just delete foo.html and foo_files should automatically be deleted as well (so no need to select both file & folder in this case).
Re: sort directories WITH files
Perhaps so, but it is not set/checked in my setup here (I haven't set explorer delete) and still works.
I'm assuming this is a Windows thing as I think it has always worked that way?
I'm assuming this is a Windows thing as I think it has always worked that way?
F4MiniMenu (Forum) - Open selected file(s) from TC in defined editor(s) - A (minimalistic) clone of F4Menu
Source at GitHub (AutoHotkey). TCSyncComments (copy file comments)
Source at GitHub (AutoHotkey). TCSyncComments (copy file comments)
Re: sort directories WITH files
It also works if you delete to recycle bin - because Windows then does the moving of the files to recycle bin.Perhaps so, but it is not set/checked in my setup here (I haven't set explorer delete) and still works.
License #524 (1994)
Danish Total Commander Translator
TC 11.51 32+64bit on Win XP 32bit & Win 7, 8.1 & 10 (22H2) 64bit, 'Everything' 1.5.0.1391a
TC 3.60b4 on Android 6, 13, 14
TC Extended Menus | TC Languagebar | TC Dark Help | PHSM-Calendar
Danish Total Commander Translator
TC 11.51 32+64bit on Win XP 32bit & Win 7, 8.1 & 10 (22H2) 64bit, 'Everything' 1.5.0.1391a
TC 3.60b4 on Android 6, 13, 14
TC Extended Menus | TC Languagebar | TC Dark Help | PHSM-Calendar
Re: sort directories WITH files
Learned something 

F4MiniMenu (Forum) - Open selected file(s) from TC in defined editor(s) - A (minimalistic) clone of F4Menu
Source at GitHub (AutoHotkey). TCSyncComments (copy file comments)
Source at GitHub (AutoHotkey). TCSyncComments (copy file comments)
SHIFT delete can easiily remove HTML _files
Thank you to hi5, gral, and petermad. I'm all set now, but let me give back by summarizing for others:
Suppose you want foo_files/ to be deleted when you manually delete foo.htm.
When you press F8 (or DEL) you will see a dialog warning box. If the box is plain, cancel and try again by pressing shift-F8. You should now see a colorful box with a colorful file icon. When you press "yes" the foo_files\ folder will also be deleted.
OPTIONAL BACKGROUND:
There are two checkboxes in Configuration Options that relate to whether foo_files/ will be automatically deleted:
With neither #3 or #4 checked you will see these dialogs:
F8=> "Do you really want to delete the selected file foo.htm?" In a plain text box.
Shift F8=>"Are you sure you want to move this file to the Recycle Bin?" In a box with a colorful icon.
With only #4 checked:
F8=> "Are you sure you want to move this file to the Recycle Bin?" In box with a colorful icon.
Shift F8=> "Do you really want to delete the selected file foo.htm?" In a plain text box.
With item #3 checked (regardless of whether "4 is unchecked or gray-checked):
F8=>"Are you sure you want to move this file to the Recycle Bin?" In a box with a colorful icon.
Shift F8-> "Are you sure you want to permanently delete this file?" In a box with a colorful icon and red X.
Conclusion: Whenver you see the box with a coloful icon, the pesky foo_files\ will be deleted.
That solves my particular problem, so my question is moot. I have no need to sort files with folders.
Suppose you want foo_files/ to be deleted when you manually delete foo.htm.
When you press F8 (or DEL) you will see a dialog warning box. If the box is plain, cancel and try again by pressing shift-F8. You should now see a colorful box with a colorful file icon. When you press "yes" the foo_files\ folder will also be deleted.
OPTIONAL BACKGROUND:
There are two checkboxes in Configuration Options that relate to whether foo_files/ will be automatically deleted:
(FYI, I prefer to leave then unchecked.)General Copy+Delete Options
#3. Use Explorer delete method (faster, cannot handle comments)
#4. F8/Del deletes to recycle bin (Shift=directly)
With neither #3 or #4 checked you will see these dialogs:
F8=> "Do you really want to delete the selected file foo.htm?" In a plain text box.
Shift F8=>"Are you sure you want to move this file to the Recycle Bin?" In a box with a colorful icon.
With only #4 checked:
F8=> "Are you sure you want to move this file to the Recycle Bin?" In box with a colorful icon.
Shift F8=> "Do you really want to delete the selected file foo.htm?" In a plain text box.
With item #3 checked (regardless of whether "4 is unchecked or gray-checked):
F8=>"Are you sure you want to move this file to the Recycle Bin?" In a box with a colorful icon.
Shift F8-> "Are you sure you want to permanently delete this file?" In a box with a colorful icon and red X.
Conclusion: Whenver you see the box with a coloful icon, the pesky foo_files\ will be deleted.
That solves my particular problem, so my question is moot. I have no need to sort files with folders.
Re: sort directories WITH files
Correct - the "colorful icon" indicates that it is a Windows dialog and not a TC box, hence Windows is handling the deletion.Conclusion: Whenver you see the box with a coloful icon, the pesky foo_files\ will be deleted.
Notice that both the Windows delete confirmation dialog and Windows deleting to Recycle bin can also be configured per drive:
In TC's Menu click "Commands" -> "Open Desktop Folder" (or run cm_OpenDesktop) - right-click on "Recycle Bin" (or the equivalent in your language) and choose "Properties" - In the Windows dialog that pops up you can configure these settings.
License #524 (1994)
Danish Total Commander Translator
TC 11.51 32+64bit on Win XP 32bit & Win 7, 8.1 & 10 (22H2) 64bit, 'Everything' 1.5.0.1391a
TC 3.60b4 on Android 6, 13, 14
TC Extended Menus | TC Languagebar | TC Dark Help | PHSM-Calendar
Danish Total Commander Translator
TC 11.51 32+64bit on Win XP 32bit & Win 7, 8.1 & 10 (22H2) 64bit, 'Everything' 1.5.0.1391a
TC 3.60b4 on Android 6, 13, 14
TC Extended Menus | TC Languagebar | TC Dark Help | PHSM-Calendar
Re: sort directories WITH files
If you check the the option "show warning when delete to recycle bin" in recycle bin properties you will always get Windows deletion dialog boxes (colorful). If you uncheck the option you will always get TC deletion dialog boxes (plain) and in such case when there is a file deleted to recycle bin, the file and bounded folder will be deleted as well, but if there is a file deleted directly, only the file will be deleted.
Conclusion:
Regardless of settings in TC preferences or Windows recycle bin properties:
To recycle bin: Whenever a file is deleted to recycle bin, the file and bounded folder is deleted as well.
Direct deletion: Whenever you see the box with a colorful icon (Windows dialog box), the file and bounded folder is deleted as well. Otherwise (plain box - TC dialog box) only the file is deleted.
Conclusion:
Regardless of settings in TC preferences or Windows recycle bin properties:
To recycle bin: Whenever a file is deleted to recycle bin, the file and bounded folder is deleted as well.
Direct deletion: Whenever you see the box with a colorful icon (Windows dialog box), the file and bounded folder is deleted as well. Otherwise (plain box - TC dialog box) only the file is deleted.