Page 1 of 1
Unzip/unrar to bottom of list?
Posted: 18 May 2016 20:13
by ardee
Hi! I used xplorer2 for years then switched to (the superior) xyplorer. I made several changes to the settings so that it fits more with the habits I'd developed (e.g., F5 now refreshes just the current folder, which is a lot faster), but there's one behavior I can't figure out how to achieve: Assuming I always use the Details view and always have it sorted so that the newest files are at the bottom, I want newly-extracted files to appear at the bottom of the list no matter their dates. Even if the zip/rar file I'm extracting from has the latest date and appears at the bottom, I want to be able to "extract here" and have the resulting files/folders also appear at the bottom rather than intermingled (sorted) with the thousands of other files/folders in the current folder. Other than that special situation (and along with putting new downloads at the bottom), I want the list to automatically remain sorted by date.
I am aware of the various settings related to sorting and how to handle new items. But I don't think the current definition of "new items" includes files that get added to the directory as a result of an "extract here"-type of operation, and I couldn't figure out a combination of settings to use so that things work the way I described.
Thank you!
-Roy.
Re: Unzip/unrar to bottom of list?
Posted: 18 May 2016 20:36
by highend
While it makes sense it "violates" sorting mechanisms (by date but files with "mixed" dates at the bottom).
It could be scripted (by switching to manual sorting and putting those files at the bottom or by putting them in a paperfolder (you did upgrade to the latest version right?) and open it in a background tab, etc.). But none of these things would happen automatically, you'd need to press a button / hit a keyboard shortcut (and have an archive selected)...
Re: Unzip/unrar to bottom of list?
Posted: 18 May 2016 21:20
by ardee
highend wrote:While it makes sense it "violates" sorting mechanisms (by date but files with "mixed" dates at the bottom).
It could be scripted (by switching to manual sorting and putting those files at the bottom or by putting them in a paperfolder (you did upgrade to the latest version right?) and open it in a background tab, etc.). But none of these things would happen automatically, you'd need to press a button / hit a keyboard shortcut (and have an archive selected)...
Yes, I upgraded. And I'll just continue using my workaround, which is to extract to a new folder rather than "here". (When I remember to.) The new folder appears at the bottom since it's now the newest thing.
A related question: what qualifies as "new items" for the checkbox setting to add new items at the bottom of the list? (We're coming to the end of my questions, I promise!)
Re: Unzip/unrar to bottom of list?
Posted: 19 May 2016 11:42
by admin
ardee wrote:A related question: what qualifies as "new items" for the checkbox setting to add new items at the bottom of the list? (We're coming to the end of my questions, I promise!)
Items that are newly created, e.g. by Edit | New | New Text File "New Text File.txt" (Ctrl+Shift+N).
Re: Unzip/unrar to bottom of list?
Posted: 19 May 2016 11:46
by highend
How a script could look like that puts extracted items (files + folders, files first) to the bottom of the current list:
Code: Select all
if (<curitem> UnLikeI "*.zip") { end 1==1; }
$zipContent = regexreplace(zip_list(, <crlf>), "\t");
$zipFolders = formatlist($zipContent, "f", <crlf>, "*\*");
$zipFolders = formatlist(regexreplace($zipFolders, "^(.*?(?=\\))(.*?)$", "$1"), "d", <crlf>);
$zipFiles = formatlist(regexreplace($zipContent, "^.*\\.*?(\r?\n|$)"), "e", <crlf>);
zip_extract(, "");
sortbylist listpane(, , 4, <crlf>) . <crlf> . $zipFiles . <crlf> . $zipFolders;
Re: Unzip/unrar to bottom of list?
Posted: 19 May 2016 14:27
by ardee
admin wrote:ardee wrote:A related question: what qualifies as "new items" for the checkbox setting to add new items at the bottom of the list? (We're coming to the end of my questions, I promise!)
Items that are newly created, e.g. by Edit | New | New Text File "New Text File.txt" (Ctrl+Shift+N).
Thanks for clarifying that. I understood that extracted files didn't count, but I was wasn't sure about just-downloaded files (that retain their original, older dates) and files pasted in by the user (having been copied from another folder).
Cheers!
Re: Unzip/unrar to bottom of list?
Posted: 19 May 2016 14:29
by ardee
highend wrote:How a script could look like that puts extracted items (files + folders, files first) to the bottom of the current list:
Code: Select all
if (<curitem> UnLikeI "*.zip") { end 1==1; }
$zipContent = regexreplace(zip_list(, <crlf>), "\t");
$zipFolders = formatlist($zipContent, "f", <crlf>, "*\*");
$zipFolders = formatlist(regexreplace($zipFolders, "^(.*?(?=\\))(.*?)$", "$1"), "d", <crlf>);
$zipFiles = formatlist(regexreplace($zipContent, "^.*\\.*?(\r?\n|$)"), "e", <crlf>);
zip_extract(, "");
sortbylist listpane(, , 4, <crlf>) . <crlf> . $zipFiles . <crlf> . $zipFolders;
Wow, thank you so much! I hadn't gotten into the scripting feature at all yet, and that is truly impressive.
Re: Unzip/unrar to bottom of list?
Posted: 19 May 2016 16:56
by ardee
Thinking about it somewhat differently...does Windows or XYplorer have something akin to a "date/time file was added/moved to this folder" column by which one could sort? That would be what would work great in all cases (extract, paste, download, etc). If that info weren't available for a given file, it could default to using the modified date in that column.
Re: Unzip/unrar to bottom of list?
Posted: 19 May 2016 21:11
by admin
No, this data is not available in NTFS.