Skip to content
This repository was archived by the owner on Aug 29, 2018. It is now read-only.

rhc show warning everytime run a command. #762

Open
BeyondTheBoundary opened this issue Jul 30, 2016 · 7 comments
Open

rhc show warning everytime run a command. #762

BeyondTheBoundary opened this issue Jul 30, 2016 · 7 comments

Comments

@BeyondTheBoundary
Copy link

Everytime I run a rhc command, it show this warning:

/usr/lib/ruby/gems/2.3.0/gems/commander-4.2.1/lib/commander/user_interaction.rb:328: warning: constant ::TimeoutError is deprecated

I'm using Arch Linux and install it with gem install rhc. My gem list is updated.

@tobiasschuerg
Copy link

For me too. It's becaus the TimeoutError isdeprecated.
A fix should be rather simple:
http://stackoverflow.com/questions/37626020/rhc-setup-returns-warning-constant-timeouterror-is-deprecated

@BeyondTheBoundary
Copy link
Author

I'm using a workaround solution.

Using vim to edit file in which rhc.

Change first line #!/usr/bin/ruby into #!/usr/bin/ruby -W0 (silent warning)

=> Problem solved!

@rand0me
Copy link

rand0me commented Sep 21, 2016

For those, who love shell, try:

 sed 's/^#\![[:graph:]]* ruby/& -W0/' `which rhc` | sudo tee `which rhc`

Do not run it twice, otherwise you will brake everything 🎱

@notthetup
Copy link

I believe same as #744

@PotOfCoffee2Go
Copy link

@rand0me For me the sed above does it's thing - then get /usr/bin/env: invalid option -- 'W' whenever rhc runs - so had to edit rhc back to it's old warning ladden self :(

@rand0me
Copy link

rand0me commented Mar 20, 2017

@PotOfCoffee2Go Hello! That's because my solution somewhat outdated. I think if you replace #!/usr/bin/env ruby with #!/usr/bin/env ruby -W0 in file, pointed by which rhc, as mentioned here you'll get it done!

@bennesp
Copy link

bennesp commented Oct 4, 2017

An alternative that worked for me:
Write

$VERBOSE = nil

at the beginning of which rhc

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants