Patch to make a gem into a Go gem right after bundle gem
Note
This is a temporary tool until bundle gem --ext=go
is added to the bundler
- Go 1.23+
- Ruby 3.3+
- Download patch_for_go_gem.rb
- Run
bundle gem <GEM_NAME> --ext=c
- The other options for
bundle gem
are optional
- The other options for
- Run
ruby patch_for_go_gem.rb --file /path/to/GEM_NAME.gemspec --dry-run
- Run
ruby patch_for_go_gem.rb --file /path/to/GEM_NAME.gemspec
cd
to the same location asext/GEM_NAME/go.mod
- Run
go get -u github.com/ruby-go-gem/go-gem-wrapper@latest