File list shuffler / Randomizer

Discuss and announce Total Commander plugins, addons and other useful tools here, both their usage and their development.

Moderators: sheep, Hacker, Stefan2, white

Lan
Junior Member
Junior Member
Posts: 17
Joined: 2005-02-14, 11:59 UTC
Location: Denmark

File list shuffler / Randomizer

Post by *Lan »

Anybody up for this challange..!?

Here's the story:
...however I miss one functionality a lot. A shuffle/ramdomize option for "sorting" files.

For what use you might ask: Well, for copying/moving files to mp3 players. Most of the physically small mp3-players, does not have a built in shuffle/randomize function, so the files are played in the order they are written to the mp3-player.

I have tried to use the "unsorted" option, but that does not do the trick sufficiently good. Also there's no plug-in available which can do it (not one I've found anyway)

So, it would be a great thing to have a plug-in available on the web-site for this.

Reply for TotalCmd guys:
<That's an interesting idea! You may indeed ask in our plugins forum whether anyone could write a random number content plugin. It would show a random number in a custom column, so you could then sort by that column. Should be quite easy to develop...>

For this to work, the files must be written to the destination in the order they are listed after shuffling/randomizing.

Anyone who can help?

LAN
User avatar
Lefteous
Power Member
Power Member
Posts: 9497
Joined: 2003-02-09, 01:18 UTC
Location: Germany
Contact:

Post by *Lefteous »

User avatar
Clas Hortien
Member
Member
Posts: 197
Joined: 2003-03-03, 15:03 UTC

Post by *Clas Hortien »

Und wie benutze ich es jetzt ? Wenn ich eine Ansicht mit Misc definiere passiert garnichts :-| .
icfu
Power Member
Power Member
Posts: 6052
Joined: 2003-09-10, 18:33 UTC

Post by *icfu »

Du klickst auf die Spalte Random.
Click on the column Random.

Schönes Plugin mal wieder, Lefteous. :)
Nice plugin once again, Lefteous. :)

Icfu
Icfu
This account is for sale
User avatar
Clas Hortien
Member
Member
Posts: 197
Joined: 2003-03-03, 15:03 UTC

Post by *Clas Hortien »

icfu wrote:Du klickst auf die Spalte Random.
Click on the column Random.
Icfu
Erst mal eine haben und ein Stück damit weg sein...
Bei mir hat das Plugin Misc keine Spalten, Felder etc. die ich auswählen kann, nur eine leere Liste.
Lan
Junior Member
Junior Member
Posts: 17
Joined: 2005-02-14, 11:59 UTC
Location: Denmark

Post by *Lan »

Thank for the plugin Lefteous

One question: When I use the plugin, I get yes/no tags in the "random column". Every second file gets a "yes". The same file gets the same tag, so the sort order is the same every time. How can I use the plugin to make the file list random?

LAN
icfu
Power Member
Power Member
Posts: 6052
Joined: 2003-09-10, 18:33 UTC

Post by *icfu »

You have to reenter the directory to renew the sort order.

@Clas Hortien:
I just experienced the same but the problem was that I moved the misc folder. Maybe you did the same by accident. ;)

Icfu
This account is for sale
Lan
Junior Member
Junior Member
Posts: 17
Joined: 2005-02-14, 11:59 UTC
Location: Denmark

Post by *Lan »

Yes, you're right.

It works!

Definitely thanks for the fish..!!

Just a thought: Could random numbers be assigned to each file every time the column i clicked?? Then you could keep clicking until you're satisfired with the sort order. --> maby something for a future plugin ;-)

LAN
User avatar
Clas Hortien
Member
Member
Posts: 197
Joined: 2003-03-03, 15:03 UTC

Post by *Clas Hortien »

icfu wrote:I just experienced the same but the problem was that I moved the misc folder. Maybe you did the same by accident. ;)
I installed it twice from two different locations and one wasn't valid anymore.

But when i now randomize my directory not all files are shown (only ~15 upto ~30 files in the TC directory, but it contains 42 files). When i leave and reenter the directory the shown files and the amount of files differ from time to time, but all files are never shown :cry: .
User avatar
Leif
Senior Member
Senior Member
Posts: 328
Joined: 2003-02-05, 15:44 UTC
Location: Umeå, Sweden

Post by *Leif »

I need something similar. I have a text file with 30,000+ lines. And I very much would like to be able to randomize the order of these lines. Possible? How? Plugin or external prog... So far I've been using TextPad where I can sort from any column, but not randomize.
Lan
Junior Member
Junior Member
Posts: 17
Joined: 2005-02-14, 11:59 UTC
Location: Denmark

Post by *Lan »

Now I have tried the plugin on my mp3-files backwards and forwards, reentered the directory, sort by name, then by random. No matter how I do it, I end up with a lot of songs from the same artist. I dont think a yes/no tag is enough to make a file list sufficiently random. Much more randomness (is that an actual word ...) is needed.

For comparison, a good randomizer can be found in winamp. With a plugin in winamp it's possible to copy the listed (and random) files to another drive (lika a mp3 player). But it's only possible to copy, not to move. So in order to move the files, the original files have to be marked and deleted via TotalCmd's window compare.
User avatar
Lefteous
Power Member
Power Member
Posts: 9497
Joined: 2003-02-09, 01:18 UTC
Location: Germany
Contact:

Post by *Lefteous »

One question: When I use the plugin, I get yes/no tags in the "random column". Every second file gets a "yes". The same file gets the same tag, so the sort order is the same every time. How can I use the plugin to make the file list random?
You chose the the odd field. You need to chosse the random field.

You have to reenter the directory to renew the sort order.
Refresh should be enough.

2Lan
www.lefteous.de/tc/archives/misc/misc_1.02.zip

Enough randomness?
Lan
Junior Member
Junior Member
Posts: 17
Joined: 2005-02-14, 11:59 UTC
Location: Denmark

Post by *Lan »

Yes, that's it

SUPER

Many thanks to Lefteous for this plugin. You have certainly made handling of mp3 much easier.

Thanks, thanks, thanks...!!!

LAN
User avatar
Lefteous
Power Member
Power Member
Posts: 9497
Joined: 2003-02-09, 01:18 UTC
Location: Germany
Contact:

Post by *Lefteous »

2Lan
Thank you!

If you want to make a "blind" copy/move try the following:

Define a predefined selection (Show/Custom, Define or press Ctrl+F12 and Define).
In this dialog select the plugin tab. Add the following rules:
Plugin: misc Property: Random OP: > Value: 5000
Plugin: misc Property: Random OP: < Value: 20000

The larger the range between the two rules the more files we be copied. The highest possible value here is 32767.

Now save the predefined selection: "My random selection"

To use this predefined selection for copying/moving call the corresponding dialog and select your pedefined selection from the "Only files of this type" list (the predefined selections can be found at the very bottom of the list).

Surprise! :D
Lan
Junior Member
Junior Member
Posts: 17
Joined: 2005-02-14, 11:59 UTC
Location: Denmark

Post by *Lan »

2 Lefteous

The "blind" selcetion works fine.

The Randomizer does it's job well. However, when using it I have noticed a little cosmetic detail. If you want to sort according to the random-number (don't know why anyone want to do it, but nevertheless...), you have to select another directory and return to get the column sorted correctly. Refresh does not work in this case and neither does several click on the random column. Well, that's not quit true, sometines it works :-) Perhaps it has something to do with the number of files.

Again, the plugin work fine -> it does what it's born to do.

LAN
Post Reply