2005-09-23 22:33:16 +08:00
|
|
|
|
|
|
|
\section fishd fishd - Universal variable daemon
|
|
|
|
|
|
|
|
\subsection fishd-synopsis Synopsis
|
|
|
|
<tt>fishd [SECTION]</tt>
|
|
|
|
|
|
|
|
\subsection fishd-description Description
|
|
|
|
|
|
|
|
The \c fishd daemon is used to load, save and distribute universal
|
2006-01-24 07:17:06 +08:00
|
|
|
variable information. fish automatically connects to fishd via a socket
|
2005-09-23 22:33:16 +08:00
|
|
|
on startup. If no instance of fishd is running, fish spawns a new
|
|
|
|
fishd instance. fishd will create a socket in /tmp, and wait for
|
2006-01-24 07:17:06 +08:00
|
|
|
incoming connections from universal variable clients, such as fish,
|
2005-09-23 22:33:16 +08:00
|
|
|
When no clients are connected, fishd will automatically shut down.
|
|
|
|
|
2005-09-23 22:44:45 +08:00
|
|
|
\subsection fishd-commands Commands
|
|
|
|
|
2006-01-24 07:17:06 +08:00
|
|
|
Fishd works by sending and receiving commands. Each command is ended
|
2005-09-23 22:44:45 +08:00
|
|
|
with a newline. These are the commands supported by fishd:
|
|
|
|
|
|
|
|
<pre>set KEY:VALUE
|
|
|
|
set_export KEY:VALUE
|
|
|
|
</pre>
|
|
|
|
|
|
|
|
These commands update the value of a variable. The only difference
|
|
|
|
between the two is that <tt>set_export</tt>-variables should be
|
|
|
|
exported to children of the process using them. The variable value may
|
|
|
|
be escaped using C-style backslash escapes. In fact, this is required
|
|
|
|
for newline characters, which would otherwise be interpreted as end of
|
|
|
|
command.
|
|
|
|
|
|
|
|
<pre>erase KEY
|
|
|
|
</pre>
|
|
|
|
|
|
|
|
Erase the variable with the specified name.
|
|
|
|
|
|
|
|
<pre>barrier
|
|
|
|
barrier_reply
|
|
|
|
</pre>
|
|
|
|
|
2006-01-24 07:17:06 +08:00
|
|
|
A \c barrier command will result in a barrier_reply being added to
|
2005-09-24 09:31:57 +08:00
|
|
|
the end of the senders queue of unsent messages. These commands are
|
|
|
|
used to synchronize clients, since once the reply for a barrier
|
|
|
|
message returns, the sender can know that any updates available at the
|
2006-01-24 07:17:06 +08:00
|
|
|
time the original barrier request was sent have been received.
|
2005-09-23 22:33:16 +08:00
|
|
|
|
2005-09-24 09:31:57 +08:00
|
|
|
\subsection fishd-files Files
|
2005-09-23 22:33:16 +08:00
|
|
|
|
2006-01-24 07:17:06 +08:00
|
|
|
~/.fishd.HOSTNAME permanent storage location for universal variable
|
2005-09-24 09:31:57 +08:00
|
|
|
data. The data is stored as a set of \c set and \c set_export commands
|
|
|
|
such as would be parsed by fishd.
|