GSP
Quick Navigator

Search Site

Unix VPS
A - Starter
B - Basic
C - Preferred
D - Commercial
MPS - Dedicated
Previous VPSs
* Sign Up! *

Support
Contact Us
Online Help
Handbooks
Domain Status
Man Pages

FAQ
Virtual Servers
Pricing
Billing
Technical

Network
Facilities
Connectivity
Topology Map

Miscellaneous
Server Agreement
Year 2038
Credits
 

USA Flag

 

 

Man Pages
xcmd(1x) xcmd(1x)

xcmd - front-end for starting programs under X11

(1) xcmd --help

(2) xcmd [--display display] [find-options] --xcmd command

(3) xcmd [--display display] [find-options] [term-options] --cmd command

Find Options

{--iconify-and-raise | --only-raise}

Terminal Window Options

{--scroll | +scroll}
{--rxvt | --xterm}

Xcmd is a front-end for starting programs under X11. You can tell xcmd to look for a window with a specific class, resource name, or title string (using the --find-property options); if it finds one or more, xcmd will `raise' them, otherwise it will run the command you specify. You can tell xcmd to run commands that create their own windows (using --xcmd), or to run commands inside a terminal window (using --cmd) with various options.

Display version information and a summary of command syntax.
This option allows you to specify the server to connect to; see X(3x).
Run command in a terminal window (see Terminal Window Options below). If you use one of the --find-property options, xcmd only runs command if it can't find a window with that property.
Run command, with the expectation that it will create its own window. If you use one of the --find-property options, xcmd only runs command if it can't find a window with that property.

Find Options

The following options tell xcmd to search the display for a window that has the specified property. If xcmd finds one or more such windows, it raises them to the top of the display. These options are mutually exclusive.

Find windows whose class matches window-class exactly.
Find windows whose resource name matches window-resource exactly.
Find windows whose title contains the string title-substring.
Find windows whose title matches window-title exactly.
When xcmd finds a window, first iconify it, then raise it; this `flashes' a little, but it works reliably under FVWM with different X server loads. It doesn't work reliably with WindowMaker.
When xcmd finds a window, just raise it. This doesn't `flash', but it also doesn't always work with FVWM. It does work reliably with WindowMaker, as long as the window is in the current workspace. This is the default.

Terminal Window Options

The following options control the appearance of the terminal window created when you run a command with --cmd. Xcmd gives an error if you use any of these options without using --cmd.

The title to give the terminal window. If you don't specify this option, the title reverts to the resource name (see --name) if one is specified, otherwise it reverts to command.
The title to give to the terminal window when it's iconified. If you don't specify this option, the icon title reverts to the window title.
The resource name to give the terminal window. If you don't specify this option, it reverts to the default resource name for the terminal program (e.g., `xterm' for xterm(1x)).
The geometry to use for the terminal window. If you don't specify this option, it reverts to the default for the terminal program.
Additional options to pass to the terminal program; additional-options should be one argument---you may need to quote it using your favorite shell's regular syntax.
Use (--scroll) or don't use (+scroll) a scrollbar in the terminal window. If you don't specify either of these options, whether the terminal uses a scrollbar depends on its defaults and its X resource settings.
Use rxvt(1x) or xterm(1x) as the terminal program to run command in. Normally, xcmd uses the terminal program specified in the XCMD_TERM environment variable (see ENVIRONMENT below), or xterm(1x) if that variable is not set. These options override the default setting.

Here are some examples of how to use xcmd:

Run vi in a terminal window.
Run vi in a terminal window and edit ~/.Xdefaults.
Look for a Netscape window, or start one if none found.
Look for a window titled Network Configurator; if none found, use sudo to start netcfg.
Look for a window titled Mail; if none found, start pine in a terminal window titled Mail, with a resource name of xMail and no scrollbar. If the X resource `*xMail*vt100.geometry: 80x40' is set, for instance, the resulting window will be 80 columns wide by 40 lines high.

Xcmd uses an execl(3) call to run /bin/sh -c exec command, so that command inherits xcmd's process ID. Xcmd runs in the foreground by default; use your favorite shell's regular syntax to start xcmd in the background (e.g., `xcmd --find-title vi --cmd vi &' for Bourne-compatible shells).

To get the default host and display number.
To set the default terminal program to use with --cmd. Overridden by the command line.
If set to `0', `no', or `false', act as if the command-line option --only-raise was specified (this is the default if not set). If set to `1', `yes', or `true', act as if the command-line option --iconify-and-raise was specified. Any other value produces an error message. XCMD_ICONIFY is overridden by the command line.

X(3x), rxvt(1x), xterm(1x), xwininfo(1x)

Jim Knoble <jmknoble@pobox.com>

Xcmd is very loosely derived from portions of xwit by Mark Martin and David DiGiacomo and xwininfo by Mark Lillibridge. Almost none of the original code remains.

1998-Jan-03 Version 1.8

Search for    or go to Top of page |  Section 1 |  Main Index

Powered by GSP Visit the GSP FreeBSD Man Page Interface.
Output converted with ManDoc.