Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add a debug flag to know what is happening #295

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions doc/man/ruby-install.1.md
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,9 @@ https://github.com/postmodern/ruby-install#readme
Downloads the latest ruby versions and checksums from the ruby-versions
repository (https://github.com/postmodern/ruby-versions#readme).

`-d`, `--debug`
Show each command being run (set -x)

`-V`, `--version`
Prints the current ruby-install version.

Expand Down
4 changes: 4 additions & 0 deletions share/man/man1/ruby-install.1
Original file line number Diff line number Diff line change
Expand Up @@ -119,6 +119,10 @@ Downloads the latest ruby versions and checksums from the ruby\-versions
repository (https:\[sl]\[sl]github\.com\[sl]postmodern\[sl]ruby\-versions\[sh]readme)\.
.LP
.TP
\fB-d\fR, \fB--debug\fR
Show each command being run (set -x)
.LP
.TP
\fB-V\fR, \fB--version\fR
Prints the current ruby\-install version\.
.LP
Expand Down
5 changes: 5 additions & 0 deletions share/ruby-install/ruby-install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,7 @@ Options:
--no-install-deps Do not install build dependencies before installing Ruby
--no-reinstall Skip installation if another Ruby is detected in same location
-L, --latest Downloads the latest ruby versions and checksums
-d, --debug Show each command being run (set -x)
-V, --version Prints the version
-h, --help Prints this message

Expand Down Expand Up @@ -179,6 +180,10 @@ function parse_options()
force_update=1
shift
;;
-d|--debug)
set -x
shift
;;
-V|--version)
echo "ruby-install: $ruby_install_version"
exit
Expand Down