new build with curl/wget stubs
This commit is contained in:
parent
30b8404f3e
commit
3676d24f30
6 changed files with 15 additions and 16 deletions
|
|
@ -65,18 +65,9 @@ require(){
|
|||
;;
|
||||
|
||||
sh|zip)
|
||||
js '
|
||||
fetch("'$1'")
|
||||
.then( (res) => res.arrayBuffer() )
|
||||
.then( async (buf) => {
|
||||
// write to filesystem
|
||||
const term = document.querySelector("[isoterminal]").components.isoterminal.term
|
||||
await term.worker.create_file("'$(basename "$1")'", new Uint8Array(buf) )
|
||||
let cmd = String("'$1'").match(/\.zip$/) ? `/root/bin/ziprun /mnt/"'$(basename $1)'"` : "./'$1'"
|
||||
term.exec(cmd)
|
||||
})
|
||||
' > $file
|
||||
echo "[.] wrote $file"
|
||||
wget "$1" -o "$file" && \
|
||||
chmod +x "$file" && \
|
||||
"./$file"
|
||||
;;
|
||||
|
||||
*)
|
||||
|
|
|
|||
|
|
@ -1,2 +0,0 @@
|
|||
#!/bin/sh
|
||||
a-gltf-model https://coderofsalvation.github.io/xrsh-media/assets/background.glb
|
||||
|
|
@ -0,0 +1 @@
|
|||
https://corsproxy.io/?url=
|
||||
|
|
@ -12,10 +12,18 @@ for arg in $*; do
|
|||
test $arg = "-o" && shift && filename=$*
|
||||
shift
|
||||
done
|
||||
|
||||
echo "$url" | grep -qE '^http' && test -f ~/.config/wget/corsproxy && {
|
||||
proxy="$(cat ~/.config/wget/corsproxy)"
|
||||
url="${proxy}${url}"
|
||||
echo "[i] using CORS proxy: $url" 1>&2
|
||||
}
|
||||
|
||||
js '$("[isoterminal]").emit("create_file_from_url",["'$tmp'","'$url'"])'
|
||||
while sleep 0.5s; do
|
||||
printf "." 1>&2
|
||||
test "$(awk '{ print $1 }' $tmp)" = 0 && retcode=1 || retcode=0
|
||||
test -f $tmp && mv $tmp "$filename" && printf "\n" && exit $retcode
|
||||
test -f $tmp && {
|
||||
test "$(awk '{ print $1 }' $tmp)" = 0 && retcode=1 || retcode=0
|
||||
mv $tmp "$filename" && printf "\n" && exit $retcode
|
||||
}
|
||||
done
|
||||
|
|
|
|||
|
|
@ -30,3 +30,4 @@ BR2_TARGET_ROOTFS_INITRAMFS=y
|
|||
BR2_TARGET_ROOTFS_ISO9660=y
|
||||
BR2_TARGET_SYSLINUX=y
|
||||
BR2_PACKAGE_FUSESCRIPT=y
|
||||
BR2_PACKAGE_LIBVIRT_ARCH_SUPPORTS=y
|
||||
|
|
|
|||
BIN
dist/v86-linux.iso
vendored
BIN
dist/v86-linux.iso
vendored
Binary file not shown.
Loading…
Add table
Reference in a new issue