fix(utimes): change /dev/stdin to - by rasa · Pull Request #1124 · tj/git-extras

Since our shebang points to Bash, I think this shouldn't be a problem. :)

@hyperupcall It’s not a bash thing, the device doesn’t exist in the OS:

iPad:~# echo whoami | bash -
root
iPad:~# echo whoami | bash /dev/stdin
bash: /dev/stdin: No such file or directory
iPad:~# uname -a
Linux iPad 4.20.69-ish SUPER AWESOME May 20 2023 23:41:32 i686 Linux

Note that since iSH (and CloudLinux) don’t support /dev based file descriptors, other common bashisms, such as process substitution, fail too:


iPad:~# cat < <(ls -1 /dev)
bash: /dev/fd/63: No such file or directory
iPad:~# cat <<<$(ls -1 /dev)
clipboard
console
full
location
null
ptmx
pts
random
tty
tty1
tty2
tty3
tty4
tty5
tty6
tty7
urandom
zero

See ish-app/ish#164