i just need something like
touch /tmp/doing\_switching; nixos-rebuild switch; sleep 5; if \[ ! -f /tmp/done\_switching \]; then nixos-rebuild switch --rollback;
nixos-rebuild switch; sleep 5; if [ ! -f /tmp/done\_switching ]; then nixos-rebuild switch --rollback;
nixos-rebuild switch; sleep 5; if [ ! -f /tmp/done\_switching ]; then nixos-rebuild switch --rollback; fi;