Minor scripting related wishes (a generic thread)

Features wanted...
nerdweed
Posts: 593
Joined: 25 Feb 2012 07:47

Re: Minor scripting related wishes (a generic thread)

Post by nerdweed »

Perfect. Thanks.

nerdweed
Posts: 593
Joined: 25 Feb 2012 07:47

Re: Minor scripting related wishes (a generic thread)

Post by nerdweed »

Could you please give a little steroid to SC moveto and copyto - allow a way to supress the rich-copy dialog.

admin
Site Admin
Posts: 50394
Joined: 22 May 2004 16:48
Location: Cologne, Win 8.1, Win 10
Contact:

Re: Minor scripting related wishes (a generic thread)

Post by admin »

The dialog asks a question. You want me decide for you?
FAQ | XY News RSS | XY Twitter | Stay home! 🎸 Or wear a mask! 😷

nerdweed
Posts: 593
Joined: 25 Feb 2012 07:47

Re: Minor scripting related wishes (a generic thread)

Post by nerdweed »

No, I would decide in a scripted way.

If we go in a branch view and are invoking a script, I would know what I am doing. I am always hitting a No in this case and could always use a predetermined No in such scenarios. There can be four completely independent possibilites here (3 options - yes, no, cancel or show the dialog).

On the same lines, copyto and move to can make use of the on_collision field which is available for backupto. I often goto help file to see the format and stop after seeing it is backupto only. Occasionaly, do think about (ab)using backupto + delete instead of moveto, but drop the idea as it would involve actual bit copies of large files.

P.S. - I never asked before for on_collision because of the subtle difference in parameters for these 3 ops (and wrote this out of flow today)

Papoulka
Posts: 455
Joined: 13 Jul 2013 23:41

Re: Minor scripting related wishes (a generic thread)

Post by Papoulka »

+1

Having to answer the Rich Copy prompt can be a real annoyance when collecting files in on place. I had to do it at least a thousand times last year, when flattening folders manually in Branch View * and later using a script **. An override on this prompt for scripting, at least, would be a big help in such cases.

* http://www.xyplorer.com/xyfc/viewtopic. ... py#p105191
** http://www.xyplorer.com/xyfc/viewtopic. ... ch#p110893

admin
Site Admin
Posts: 50394
Joined: 22 May 2004 16:48
Location: Cologne, Win 8.1, Win 10
Contact:

Re: Minor scripting related wishes (a generic thread)

Post by admin »

Why not simply use backupto()?
FAQ | XY News RSS | XY Twitter | Stay home! 🎸 Or wear a mask! 😷

nerdweed
Posts: 593
Joined: 25 Feb 2012 07:47

Re: Minor scripting related wishes (a generic thread)

Post by nerdweed »

I already answered that :ninja:

BackupTo is an alternative to CopyTo. Not a very good alternative for MoveTo for moves on the same partition.

admin
Site Admin
Posts: 50394
Joined: 22 May 2004 16:48
Location: Cologne, Win 8.1, Win 10
Contact:

Re: Minor scripting related wishes (a generic thread)

Post by admin »

OK, but that wish is more complex than it might seem. Maybe next year.
FAQ | XY News RSS | XY Twitter | Stay home! 🎸 Or wear a mask! 😷

SammaySarkar
Posts: 4235
Joined: 12 Mar 2014 17:27
Location: Asteroid B-612 / Dhaka
Contact:

Re: Minor scripting related wishes (a generic thread)

Post by SammaySarkar »

can formatdate() support msecs
?
    formatdate(property('System.DateCreated',$f), 'yyyy.dd.mm_hh.nn.ss.fff')
Icon Names | Onyx | Undocumented Commands | xypcre
[ this user is asleep ]

admin
Site Admin
Posts: 50394
Joined: 22 May 2004 16:48
Location: Cologne, Win 8.1, Win 10
Contact:

Re: Minor scripting related wishes (a generic thread)

Post by admin »

It does already, but property('System.DateCreated') does not return any msecs. The shell dumbs down NTFS data and ignores the msec part.

Getting the exact time now, for instance:

Code: Select all

echo formatdate(, 'yyyy.dd.mm_hh.nn.ss.fff');
FAQ | XY News RSS | XY Twitter | Stay home! 🎸 Or wear a mask! 😷

TheQwerty
Posts: 4353
Joined: 03 Aug 2007 22:30

Re: Minor scripting related wishes (a generic thread)

Post by TheQwerty »

*bump*

I apparently forgot to bump this old wish but I found myself with another need for it today...
TheQwerty wrote:Please sir, I want some more. :(

This wish comes with free documentation! :wink:

History.txt:

Code: Select all

    + SC get got a new named argument "listofcommands".
      Syntax: get("listofcommands", [flags], [separator=CRLF])
        flags: (bit field)
          1 = Prepend Command IDs, separated by a TAB.
          2 = Append Keyboard Shortcuts, separated by a TAB.
        return:       The list of all commands.
      Examples:
        text get("listofcommands");
        text get("listofcommands", 3);
CHM:

Code: Select all

<Under:
::help('idh_scripting_comref.htm#idh_sc_get');
>

"listofcommands", [flags], [separator=CRLF]
Returns the list of all commands.
flags: (bit field)
 1 = Prepend Command IDs, separated by a TAB.
 2 = Append Keyboard Shortcuts, separated by a TAB.
return:       The list of all commands.
Examples:
text get("listofcommands");
text get("listofcommands", 3);
:beer:

SammaySarkar
Posts: 4235
Joined: 12 Mar 2014 17:27
Location: Asteroid B-612 / Dhaka
Contact:

Re: Minor scripting related wishes (a generic thread)

Post by SammaySarkar »

+1 to TQ's wish.

Please andAnd please add a separator parameter to thumbsconf, continuing the setlayout parallel.
Icon Names | Onyx | Undocumented Commands | xypcre
[ this user is asleep ]

admin
Site Admin
Posts: 50394
Joined: 22 May 2004 16:48
Location: Cologne, Win 8.1, Win 10
Contact:

Re: Minor scripting related wishes (a generic thread)

Post by admin »

Ok, and Ok.

Can't resist a copy+paste job. :tup:
FAQ | XY News RSS | XY Twitter | Stay home! 🎸 Or wear a mask! 😷

TheQwerty
Posts: 4353
Joined: 03 Aug 2007 22:30

Re: Minor scripting related wishes (a generic thread)

Post by TheQwerty »

admin wrote:Ok, and Ok.
Thank you! :beer:
admin wrote:Can't resist a copy+paste job. :tup:
Guess I should do some digging because I know you've resisted a few in the past and now might be a good time to bump them! :titter:

admin
Site Admin
Posts: 50394
Joined: 22 May 2004 16:48
Location: Cologne, Win 8.1, Win 10
Contact:

Re: Minor scripting related wishes (a generic thread)

Post by admin »

Noooo, mercy!!! :ninja:
FAQ | XY News RSS | XY Twitter | Stay home! 🎸 Or wear a mask! 😷

Post Reply