A

Internal procedures

Previous Next Index


Here are listed all the internal procedures that are usable in the configuration editors (Button editor, Extension editor) with brief description. In case you wonder why there is no <side> defined as argument, the editors automatically insert the correct side to the arguments. With the <Execute> item you can use the external Unix-commands.

Remember the operation specifiers with which you can get the correct result:

Examples:
<Execute> unzip %f -d %d
* Here %f will be replaced with the package name you have selected and %d with the directory on the other side.

<Execute> unzip %f -d %c
* Here %f will be replaced with the package name you have selected and %c with the directory on that side.

<Execute> zip -r %o2'More options:' %d%o1'Name of package:' %f
* Here %o2 will be replaced with additional flags (if needed) and %o1 with the package name. %d will be the directory on the other side and %f will be the files to be added.
The options for the operations are:

Procedures:

Usage:
BE = Button editor
EE = Extension editor


ChangeDir <dirname>       BE
Changes the directory listing in the side concerned to be that of <dirname>. A specific procedure is needed to update historymenus etc. You can start the path with "~/" or "~USER/".

Copy       BE
Copies the selected files to the directory on the opposite side. If nothing is selected, does nothing.

CopyAs       BE
Copies the selected files to the directory on the opposite side. For each of the files asks for the new name. If nothing is selected, does nothing.

Delete       BE
Deletes the selected files. If nothing is selected, does nothing.

DirSize       BE
Calculates the size of the selected directories with all its contents and subdirectories. The size appears as with files. If selected item is a file, does nothing.

Execute       BE,EE
With this item you can use the external Unix-commands. Use the operators above.

Grep       BE
This asks a string and a file pattern. It searches all the files matching pattern in the current directory and its subdirectories for the string. The results are then printed to the OutputWindow with filenames and linenumbers.
NOTE!
Unlike other operations, this procedure does not care whether you have files selected or not.

MakeDir       BE
Makes a new subdirectory to the directory in the side concerned. Asks for the name. If a directory or a file with the specified name already exists, does nothing.

Mount <device>       BE
Mounts the <device> and changes the listing in the side concerned to the correct directory. In order to get this work properly, you should have a line "<device> <directory> <filesys> <options>" in your /etc/fstab file.
Example of line: /dev/fd0 /mnt/ msdos defaults,exec,user 0 0
Very handy in floppy and cdrom mounting.

Move       BE
Moves the selected files to the directory on the opposite side. If nothing is selected, does nothing.

PatternSel       BE
Asks for the pattern to be selected and then selects all files in the current directory matching that pattern (uses regular expressions). All previous selections remain untouched and the selection size is updated automatically. Remember that this selects files only, so if you select pattern "*", directories remain unselected (if they are not selected earlier).
NOTE! This is the only ActionButton operation that works with Virtual Filesystem.

ProtEditor       BE
Opens a dialog for the selected files and directories where you can change the protection modes. Simply check those rights you want to give to that file and click "OK". If you click "Cancel", the operation will skip that file.

ReadFiles       BE
Use this to view the contents of a file in the Output Window. This prevents X-Files from hanging when using 'cat' and Output Window with no arguments. If nothing is selected, does nothing.
NOTE!
This has changed slightly, so if you have an old button that uses this you must do following: go to the Button Editor, select your button and reselect the command [ReadFiles] to it. Then save.

Rename       BE
Renames the selected files asking the new name for each of the files. If nothing is selected, does nothing.

VirtualLha       BE, EE
The side concerned goes to virtual lharc -mode. The selected file should be a single lharc-file.

VirtualTar       BE, EE
The side concerned goes to virtual tar -mode. The selected file should be a single tar-file. Can also be a compressed tar-package.

VirtualZip       BE, EE
The side concerned goes to virtual zip -mode. The selected file should be a single zip-file.

Previous Next Index