ruby: fix NameError
ruby sample: support --version