blob 5c9988c994ed9b942329055673b332d0aa918957 1162 bytes (raw)
name: host/rootfs/image/etc/s6-linux-init/run-image/service/serial-getty-generator/run # note: path name is non-authoritative(*)
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
| | #!/bin/execlineb -WS1
# SPDX-License-Identifier: EUPL-1.2+
# SPDX-FileCopyrightText: 2024-2025 Alyssa Ross <hi@alyssa.is>
cgroup-setup -- $1
piperw 3 4
background {
fdclose 3
fdmove 2 4
inotifywait -e MODIFY /sys/class/tty/console/active
}
fdclose 4
importas -i inotifywait_pid !
foreground {
if { fdmove 0 3 grep -qx "Watches established." }
background { fdmove 0 3 cat }
fdclose 3
# Wait until inotifywait is ready before updating serial gettys,
# so that changes won't be missed in between updating and starting
# inotifywait.
pipeline { s6-instance-list /run/service/serial-getty }
pipeline { sort }
fdmove -c 3 0
redirfd -r 0 /sys/class/tty/console/active
pipeline { tr " " "\n" }
pipeline { sort }
pipeline { comm -3 - /proc/self/fd/3 }
forstdin -Ep line
case -N $line {
" ?tty[0-9]*" { }
" (.*)" {
importas -i tty 1
s6-instance-delete /run/service/serial-getty $tty
}
}
s6-instance-create /run/service/serial-getty $line
}
# Block until the active consoles change, then let s6 restart us.
unexport EXECLINE_STRICT # https://skarnet.org/lists/skaware/2246.html
wait -- $inotifywait_pid
|
debug log:
solving 5c9988c994ed9b942329055673b332d0aa918957 ...
found 5c9988c994ed9b942329055673b332d0aa918957 in https://inbox.spectrum-os.org/spectrum-devel/20260620-cgroups-v2-1-ccae224b6c85@gmail.com/ ||
https://inbox.spectrum-os.org/spectrum-devel/20260620-cgroups-v1-1-0e5abf35101b@gmail.com/
found bf66ab0878fc6d8e77ca71a4a89e50c139a6bb11 in https://spectrum-os.org/git/spectrum
preparing index
index prepared:
100755 bf66ab0878fc6d8e77ca71a4a89e50c139a6bb11 host/rootfs/image/etc/s6-linux-init/run-image/service/serial-getty-generator/run
applying [1/1] https://inbox.spectrum-os.org/spectrum-devel/20260620-cgroups-v2-1-ccae224b6c85@gmail.com/
diff --git a/host/rootfs/image/etc/s6-linux-init/run-image/service/serial-getty-generator/run b/host/rootfs/image/etc/s6-linux-init/run-image/service/serial-getty-generator/run
index bf66ab0878fc6d8e77ca71a4a89e50c139a6bb11..5c9988c994ed9b942329055673b332d0aa918957 100755
Checking patch host/rootfs/image/etc/s6-linux-init/run-image/service/serial-getty-generator/run...
Applied patch host/rootfs/image/etc/s6-linux-init/run-image/service/serial-getty-generator/run cleanly.
skipping https://inbox.spectrum-os.org/spectrum-devel/20260620-cgroups-v1-1-0e5abf35101b@gmail.com/ for 5c9988c994ed9b942329055673b332d0aa918957
index at:
100755 5c9988c994ed9b942329055673b332d0aa918957 host/rootfs/image/etc/s6-linux-init/run-image/service/serial-getty-generator/run
(*) Git path names are given by the tree(s) the blob belongs to.
Blobs themselves have no identifier aside from the hash of its contents.^
Code repositories for project(s) associated with this public inbox
https://spectrum-os.org/git/doc
https://spectrum-os.org/git/mktuntap
https://spectrum-os.org/git/spectrum
https://spectrum-os.org/git/ucspi-vsock
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).