Run a ruby script with stackprof.
$ gem install stackprof-run
stackprof-run
executes received command with stackprof.
# Run RuboCop with stackprof
$ stackprof-run rubocop some_ruby_file.rb
# Run a rake task
$ stackprof-run bin/rake some_task
$ stackprof-run --help
Usage: stackprof-run [options] command [command options]
-m, --mode=MODE :cpu(default), :wall, :object
-o, --out=FILE Output file name. (default: stackprof-out)
-i, --interval=INTERVAL
-no-aggregate
-r, --raw
This gem dependents which
command, so, it does not work in Windows.
Bug reports and pull requests are welcome on GitHub at https://github.com/pocke/stackprof-run.
These codes are licensed under CC0.