# shellcheck shell=dash

___x_cmd_luarocks_install(){
    (
        # TODO: Can't find gcc,cc,make etc
        if ! ___x_cmd_hascmd gcc; then
            ___x_cmd lua ensurecc || return 1
        fi

        ___x_cmd_hascmd unzip || {
            luarocks:info "Install unzip -> x cosmo use unzip"
            ___x_cmd cosmo use unzip || return 1
        }

        ___x_cmd_luarocks_exec install "$@"
    )
}
