Sorbet install: Difference between revisions
From wikinotes
No edit summary |
|||
Line 50: | Line 50: | ||
<blockquote> | <blockquote> | ||
You can require gems during the <code>srb gems</code> execution which executes shims to help with dynamic code | You can require gems during the <code>srb gems</code> execution which executes shims to help with dynamic code | ||
<syntaxhighlight lang=""> | <syntaxhighlight lang="ruby"> | ||
# sorbet/tapioca/require.rb | # sorbet/tapioca/require.rb | ||
require "rbi" | |||
require "spoom" | |||
require "thor" | require "thor" | ||
require "yard-sorbet" | |||
</syntaxhighlight> | </syntaxhighlight> | ||
</blockquote><!-- Tapioca Requires --> | </blockquote><!-- Tapioca Requires --> | ||
</blockquote><!-- Shim Generation / Ignores --> | </blockquote><!-- Shim Generation / Ignores --> |
Revision as of 20:18, 4 November 2023
Initial Setup
Gemfile
source "https://rubygems.org" gem "sorbet" gem "sorbet-runtime" gem "sorbet-static" gem "tapioca"Init
bundle exec srb initDependencies
aur sync watchman-bin pacman -S watchman-bin
Shim Generation / Ignores
Ignore Directories
# ${PROJECT}/sorbet/config --ignore=/tmp/ --ignore=/vendor/bundleShims
bundle exec srb gems # generate shims for gemsTapioca Requires
You can require gems during the
srb gems
execution which executes shims to help with dynamic code# sorbet/tapioca/require.rb require "rbi" require "spoom" require "thor" require "yard-sorbet"