summaryrefslogtreecommitdiff
path: root/man/wmiir.man1
blob: 031ec0f629a89c9845f9500fffcb7cd1fdc748e0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
wmiir
wmii-@VERSION@
Oct, 2009

%!includeconf: header.t2t

= NAME =

wmiir - The wmii 9P filesystem client

= SYNOPSIS =

wmiir [-a <address>] [-b] {create | ls [-dlp] | read | remove | write} <file> +
wmiir [-a <address>] [-b] xwrite <file> <data> ... +
wmiir -v

= DESCRIPTION =

`wmiir` is a simple 9P filesystem client which ships with `wmii`, and connects
to its virtual filesystem by default. `wmiir` is most often used to query and
issue commands to `wmii`, both from the command line and from its `sh`-based
configuration scripts.

Since the default encoding of 9P filesystems is UTF-8, `wmiir`
assumes that all data read and written is text data and
translates to or from your locale character encoding as
necessary. When working with non-text data in a non-UTF-8
locale, the _-b_ flag should be specified to disable this
behavior.

= ARGUMENTS =

: -a
        The address at which to connect to `wmii`.
: -b
	With the _-b_ flag, data that you intend to read or
	write is treated as binary data.
:
= COMMANDS =

The following commands deal with 9P filesystems.

: create <file>
        Creates a new file or directory in the filesystem. Permissions and
        file type are inferred by `wmii`. The contents of the standard input
        are written to the new file.
: ls [-dlp] <path>
        Lists the contents of <path>.

        Flags:
        >>
        : -d
                Don't list the contents of directories.
        : -l
                Long output. For each file, list its permissions, owner,
                group, size (bytes), mtime, and name.
        : -p
                Print the full path to each file.
        <<
: read <file>
        Reads the entire contents of a file from the filesystem. Blocks until
        interrupted or EOF is received.

        Synonyms: `cat`
: remove <path>
        Removes <path> from the filesystem.

        Synonyms: `rm`
: write <file>
        Writes the contents of the standard input to <file>.
: xwrite <file> <data> ...
        Writes each argument after <file> to the latter.
:

Additionally, wmiir provides the following utility commands relevant
to scripting wmii:

: namespace
	Prints the current wmii namespace directory, usually
	equivalent to /tmp/ns.$USER.${DISPLAY%.0}, but possibly
	different depending on the value of $NAMESPACE and
	$WMII_NAMESPACE.

	Synonyms: `ns`
: setsid [-0 <argv0>] [-f] <command>
	Executes the given command after setting the session id (see
	setsid(2)). If _-0_ is given, the command is run with the
	given value as argv[0]. For instance, to run sh as a login
	shell, one might run

```        wmiir setsid \-0 \-sh sh
	If _-f_ is given, wmiir will fork into the background before
	executing the command.
: proglist [--] <directory> ...
	Lists all executable commands in the given directories.

= ENVIRONMENT =

: $WMII_ADDRESS
        The address at which to connect to wmii.
: $NAMESPACE
        The namespace directory to use if no address is
        provided.
:

= SEE ALSO =
wmii(1), libixp[2]

[1] http://www.suckless.org/wiki/wmii/tips/9p_tips +
[2] http://libs.suckless.org/libixp