Helps you keep an eye on your RubyMotion iOS app's memory and CPU usage.
Adds a little UILabel in the top left of the screen that shows CPU % and memory usage in MB.
class AppDelegate def application(app, didFinishLaunchingWithOptions: options) # ... MemWatcher.watch true end end
env: option controls what environments MemWatcher will watch in. It defaults to
"development" and can be a string or array of acceptable RubyMotion environments.
MemWatcher.watch(env: [ "development", "test" ])
If you want to attach the view to another view, provide it:
- It only reports on the current app main process.
- I have no idea how accurate it is. It does accurately show memory leaks, from what I can see.
- Fork it
- Create your feature branch (
git checkout -b my-new-feature)
- Commit your changes (
git commit -am 'Add some feature')
- Push to the branch (
git push origin my-new-feature)
- Create new Pull Request