Am new to shell scripting, and it makes me wonder why the following snippet does not work in zsh but does in bash? Is there a zsh equivalent of the same snippet? I get error parse error near `200'
(
flock -e 200
echo "In critical section"
sleep 5
) 200>/tmp/blah.lockfile
echo "After critical section"
The above snippet of code is from src: https://stackoverflow.com/a/13551882/15087532
zshhas a built-inflockin itszsystemmodule that would be better to use inzshscripts.