rokosun-patch-1
main
Also implemented some changes suggested by [Shellcheck](https://github.com/koalaman/shellcheck)