'\" t .\" Title: dbus-run-session .\" Author: [FIXME: author] [see http://www.docbook.org/tdg5/en/html/author] .\" Generator: DocBook XSL Stylesheets vsnapshot .\" Manual: User Commands .\" Source: D-Bus 1.12.20 .\" Language: English .\" .TH "DBUS\-RUN\-SESSION" "1" "" "D\-Bus 1\&.12\&.20" "User Commands" .\" ----------------------------------------------------------------- .\" * Define some portability stuff .\" ----------------------------------------------------------------- .\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .\" http://bugs.debian.org/507673 .\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html .\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .ie \n(.g .ds Aq \(aq .el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- .\" disable hyphenation .nh .\" disable justification (adjust text to left margin only) .ad l .\" ----------------------------------------------------------------- .\" * MAIN CONTENT STARTS HERE * .\" ----------------------------------------------------------------- .SH "NAME" dbus-run-session \- start a process as a new D\-Bus session .SH "SYNOPSIS" .HP \w'\fBdbus\-run\-session\fR\ 'u \fBdbus\-run\-session\fR [\-\-config\-file\ \fIFILENAME\fR] [\-\-dbus\-daemon\ \fIBINARY\fR] [\-\-] \fIPROGRAM\fR [\fIARGUMENTS\fR...] .HP \w'\fBdbus\-run\-session\fR\ 'u \fBdbus\-run\-session\fR \-\-help .HP \w'\fBdbus\-run\-session\fR\ 'u \fBdbus\-run\-session\fR \-\-version .SH "DESCRIPTION" .PP \fBdbus\-run\-session\fR is used to start a session bus instance of \fBdbus\-daemon\fR from a shell script, and start a specified program in that session\&. The \fBdbus\-daemon\fR will run for as long as the program does, after which it will terminate\&. .PP One use is to run a shell with its own \fBdbus\-daemon\fR in a text\-mode or SSH session, and have the \fBdbus\-daemon\fR terminate automatically on leaving the sub\-shell, like this: .PP dbus\-run\-session \-\- bash .PP or to replace the login shell altogether, by combining \fBdbus\-run\-session\fR with the \fBexec\fR builtin: .PP exec dbus\-run\-session \-\- bash .PP Another use is to run regression tests and similar things in an isolated D\-Bus session, to avoid either interfering with the "real" D\-Bus session or relying on there already being a D\-Bus session active, for instance: .PP dbus\-run\-session \-\- make check .PP or (in \fBautomake\fR(1)): .sp .if n \{\ .RS 4 .\} .nf AM_TESTS_ENVIRONMENT = export MY_DEBUG=all; LOG_COMPILER = dbus\-run\-session AM_LOG_FLAGS = \-\- .fi .if n \{\ .RE .\} .SH "OPTIONS" .PP \fB\-\-config\-file=\fR\fIFILENAME\fR, \fB\-\-config\-file\fR \fIFILENAME\fR .RS 4 Pass \fB\-\-config\-file=\fR\fIFILENAME\fR to the bus daemon, instead of passing it the \fB\-\-session\fR argument\&. See \fBdbus-daemon\fR(1)\&. .RE .PP \fB\-\-dbus\-daemon=\fR\fIBINARY\fR, \fB\-\-dbus\-daemon\fR \fIBINARY\fR .RS 4 Run \fIBINARY\fR as \fBdbus-daemon\fR(1), instead of searching the \fBPATH\fR in the usual way for an executable called \fBdbus\-daemon\fR\&. .RE .PP \fB\-\-help\fR .RS 4 Print usage information and exit\&. .RE .PP \fB\-\-version\fR .RS 4 Print the version of dbus\-run\-session and exit\&. .RE .SH "EXIT STATUS" .PP \fBdbus\-run\-session\fR exits with the exit status of \fIPROGRAM\fR, 0 if the \fB\-\-help\fR or \fB\-\-version\fR options were used, 127 on an error within \fBdbus\-run\-session\fR itself, or 128+\fIn\fR if the \fIPROGRAM\fR was killed by signal \fIn\fR\&. .SH "ENVIRONMENT" .PP \fBPATH\fR is searched to find \fIPROGRAM\fR, and (if the \-\-dbus\-daemon option is not used or its argument does not contain a \fB/\fR character) to find \fBdbus\-daemon\fR\&. .PP The session bus\*(Aq address is made available to \fIPROGRAM\fR in the environment variable \fBDBUS_SESSION_BUS_ADDRESS\fR\&. .PP The variables \fBDBUS_SESSION_BUS_PID\fR, \fBDBUS_SESSION_BUS_WINDOWID\fR, \fBDBUS_STARTER_BUS_TYPE\fR and \fBDBUS_STARTER_ADDRESS\fR are removed from the environment, if present\&. .SH "BUGS" .PP Please send bug reports to the D\-Bus mailing list or bug tracker, see \m[blue]\fBhttp://www\&.freedesktop\&.org/software/dbus/\fR\m[] .SH "SEE ALSO" .PP \fBdbus-daemon\fR(1), \fBdbus-launch\fR(1)