[comp.sys.amiga.tech] Moving multiple files Was: Too many devices? Was: ....

pete@violet.berkeley.edu (Pete Goodeve) (12/05/88)

In <802@quintus.UUCP> Peter Schachte suggests:

> How about an IconX script to copy multiple files.  You'd double-click it
> instead of dragging it, but otherwise it would be straitforward.  It
> could copy files to C:, L:, DEVS:, LIBS:, or wherever.  If the files
> were already there, it could offer to overwrite them, remove them
> (uninstall), or do nothing.  Easy.


I have a trick that I've used with Xicon 2 (as opposed to IconX (:-)),
which seems to work quite well.  (I don't think IconX has suitable
ToolTypes for this, actually.)

Basically, what you do is attach a PROJECT icon to the drawer containing
the files you want to move as a group, instead of the usual DRAWER type.
WorkBench doesn't care that the icon is the "wrong" type when you drag it
to another disk, and happily moves (copies) the directory and all its
contents.

You then have to set up the icon so that when you double-click on it it
installs the system, or whatever you want it to do.  I do this by putting a
copy of Xicon within the drawer as well, together with a command script to
perform the necessary, and set the "Default Tool" in the icon to

                "drawername/xicon"

This way, the copy of Xicon within the directory gets executed wherever you
have moved things to.

To prevent it trying to execute the drawer itself as a "script" (!), I have
to include the ToolType

                MODE=noscript

(plus whatever other mode settings, like 'nowindow', I might want).  And to
get it to find and execute my script I also have to supply the ToolType

                SCRIPT=drawername/scriptname

Essentially the script takes over from there, though depending on the
application one will probably have to use some of Xicon's other
capabilities, such as finding out which directory the icon was invoked
from.

There's nothing special about Xicon in the general principle of all this,
of course.  You could supply ANY suitable program name as the Default Tool
to get invoked when you double-click on the "drawer";  it's just often
convenient to use a command script to do the work.

                                            -- Pete --