We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
In Rake task, I prefer sh to system to execute external commands. Because sh raises an error when the command exits with non-zero. It is safer.
sh
system
task :foo do system 'false' # It does not raise any errors sh 'false' # It raises an error. end
Note: I think system in not void context is ok. So the cop should not add any offense for the following code.
task :foo do # It does not raise, but handled. if system 'cmd' # ... end end
The text was updated successfully, but these errors were encountered:
No branches or pull requests
In Rake task, I prefer
sh
tosystem
to execute external commands.Because
sh
raises an error when the command exits with non-zero. It is safer.Note: I think
system
in not void context is ok. So the cop should not add any offense for the following code.The text was updated successfully, but these errors were encountered: