patches and low-level development discussion
 help / color / mirror / code / Atom feed
75e0c315050c4afa43a282e4b91d292e68311ccb blob 1025 bytes (raw)

 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
 
#!/bin/execlineb -P
# SPDX-License-Identifier: EUPL-1.2+
# SPDX-FileCopyrightText: 2022 Alyssa Ross <hi@alyssa.is>

cd /dev
importas -i devname DEVNAME

backtick -E ext {
  backtick -x extspec { redirfd -w 2 /dev/null cat /run/param/ext }
  ifelse { redirfd -w 1 /dev/null printenv extspec }

  {
    importas -iu extspec extspec
    findfs $extspec
  }

  pipeline {
    backtick -E diskpath {
      pipeline { lsblk -lnpo KNAME,PKNAME }
      backtick -E rootpart {
        pipeline { veritysetup status root-verity }
        awk -F ":[[:blank:]]*" "$1 ~ /^[[:blank:]]*data device$/ {print $2; exit}"
      }
      awk -v rootpart=${rootpart} "$1 == rootpart {print $2; exit}"
    }
    lsblk -lnpo PARTTYPE,NAME $diskpath
  }
  awk "$1 == \"9293e1ff-cee4-4658-88be-898ec863944f\" {print $2; exit}"
}

if {
  backtick -E extinode { redirfd -w 2 /dev/null stat -Lc %d:%i $ext }
  backtick -E inode { stat -Lc %d:%i $devname }
  test $inode = $extinode
}

if { ln -s $devname ext }
if { mount ext /ext }
/etc/mdev/listen ext
debug log:

solving 75e0c31 ...
found 75e0c31 in https://spectrum-os.org/git/spectrum

Code repositories for project(s) associated with this public inbox

	https://spectrum-os.org/git/crosvm
	https://spectrum-os.org/git/doc
	https://spectrum-os.org/git/mktuntap
	https://spectrum-os.org/git/nixpkgs
	https://spectrum-os.org/git/spectrum
	https://spectrum-os.org/git/ucspi-vsock
	https://spectrum-os.org/git/www

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).