Blob


1 .TH 9 1
2 .SH NAME
3 9, 9.rc \- run Plan 9 commands
4 .SH SYNOPSIS
5 .B 9
6 .I cmd
7 [
8 .I args
9 \&...
10 ]
11 .PP
12 .B .
13 .B 9
14 (from
15 .IR sh (1))
16 .PP
17 .B 9.rc
18 .I cmd
19 [
20 .I args
21 \&...
22 ]
23 .PP
24 .B .
25 .B 9.rc
26 (from
27 .IR rc (1))
28 .SH DESCRIPTION
29 Because Plan 9 supplies commands with the same name as but different
30 behavior than many basic Unix system commands
31 (e.g.,
32 .BR grep ,
33 .BR sed ,
34 .BR mkdir ,
35 .BR rm ),
36 it is not recommended to run with the Plan 9 bin directory
37 ahead of the system directories.
38 .PP
39 .I 9
40 is a shell script that sets up a Plan 9 environment and runs
41 .I cmd .
42 It sets
43 .B $PLAN9
44 if necessary
45 and adds
46 .B $PLAN9/bin
47 to the beginning of
48 .B $PATH
49 before running
50 .IR cmd .
51 .PP
52 If run with no arguments,
53 .B 9
54 does not do anything, so it can be invoked from
55 .IR sh -style
56 shells using
57 .B .
58 .B 9
59 in order to make the current shell start running in the Plan 9 environment.
60 .PP
61 .I 9.rc
62 is the same as
63 .I 9
64 but written for use by the shell
65 .IR rc (1).
66 .SH EXAMPLES
67 Search for greek in the password file:
68 .IP
69 .EX
70 $ 9 grep '[α-ζ]' /etc/passwd
71 .EE
72 .PP
73 Start an
74 .IR rc (1)
75 with the Plan 9 commands in the path before the system commands.
76 .IP
77 .EX
78 9 rc
79 .EE
80 .SH SOURCE
81 .B \*9/bin/9
82 .br
83 .B \*9/bin/9.rc
84 .SH SEE ALSO
85 .IR intro (1)