~kvik/mq

ref: d8035d7ee34c4f800509bb0680ad678fef612f99 mq/man/1/pin -rw-r--r-- 1.2 KiB
d8035d7ekvik pin(1): don't end in empty section 1 year, 2 months ago
                                                                                
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
.TH PIN 1
.SH NAME
pin \- pinned I/O shell
.SH SYNOPSIS
pin
[
.B -acw
] [
.B -m
.I mtpt
] [
.B -s
.I mq
] [
.I id
] [
.I command
]
.SH DESCRIPTION
.PP
.B Pin
manages persistent sessions for long-running commands.
It is used to create, join, and control sessions for programs
connected to a named
.IR mq (4)
stream group.
.PP
The 
.B -c
flag creates a session
.I id
running
.I command,
or
.B rc -i
if command is not given.
.PP
The
.B -a
flag attaches to a session
.I id.
.PP
The -w
flag writes the
.I command
string, or standard input if not given, to
a session's input stream.
.PP
Under the hood,
.I pin
expects an
.IR mq (4)
instance mounted on
.B /n/pin
or
.I mtpt
in case the
.B -m
option is given.
If no such mount is present,
.I pin
mounts the channel posted on
.B /srv/pin-$user
or
.B /srv/$mq
in case the
.B -s
option is given, creating it if needed.
.SH EXAMPLES
.PP
Pin an
.BR rc (1)
shell and attach to it
.EX
	pin -ca myshell
.EE
.PP
Pin another program
.EX
	pin -c remote rcpu -h remote
.EE
.PP
Send input to a pinned program
.EX
	pin -w myshell echo 'hi, shell'
.EE
or
.EX
	echo 'echo hi, shell' | pin -w myshell
.EE
.SH SEE ALSO
.IR mq (4)
.SH SOURCE
.EX
git://src.a-b.xyz/mq
.EE