Skip to content

Latest commit

 

History

History
53 lines (34 loc) · 1.66 KB

File metadata and controls

53 lines (34 loc) · 1.66 KB

Development

Setup

In your terminal run:

bundle install
bin/server

ℹ️ In iTerm you may need to press Option + A to accept screen refreshing. ℹ️ In Ghostty the matrix flickers a little but it adds to the effect. Ghostty it's only 10fps!

Development

After checking out the repo, run bin/setup to install dependencies. Then, run rake spec to run the tests. You can also run bin/console for an interactive prompt that will allow you to experiment.

To install this gem onto your local machine, run bundle exec rake install. To release a new version, update the version number in version.rb, and then run bundle exec rake release, which will create a git tag for the version, push git commits and the created tag, and push the .gem file to rubygems.org.

Debugging

Debug Mode

Set RAIN_DEBUG=1 to block the current asynchronous fiber and show the backtrace when an exception is raised.

ℹ️ This will make your development experience much better.

Asynchronous Mode

RAIN_ASYNC_MODE=1 is the default. In this async environment we must first block the fiber:

Fiber.blocking { binding.irb }

https://socketry.github.io/async/guides/debugging/index

Synchronous Mode

Set RAIN_ASYNC_MODE=0 to run the server synchronously, making normal debugging techniques easy:

p variable
puts variable
binding.pry # Debug mode requires pry for you

Testing

Run all tests with bundle exec rspec. Add the SHOW_OUTPUT=1 flag to see the terminal output of some of the feature tests.

Contributing

Bug reports and pull requests are welcome on GitHub at https://codeberg.org/raindeer/raindeer.