Sha256: 8eaec996f0b06590a76ea98fa93beec32801568e21736e7661fd5f8826ec0a68

Contents?: true

Size: 1.03 KB

Versions: 1

Compression:

Stored size: 1.03 KB

Contents

D = Steep::Diagnostic

FileUtils.mkpath("tmp")
tmp_rbs_dir = Pathname("tmp/rbs-sig")

definition = Bundler::Definition.build(Pathname("Gemfile"), Pathname("Gemfile.lock"), nil)
rbs_dep = definition.dependencies.find {|dep| dep.name == "rbs" }
if (source = rbs_dep&.source).is_a?(Bundler::Source::Path)
  unless tmp_rbs_dir.directory?
    FileUtils.ln_s(Pathname.pwd + source.path + "sig", tmp_rbs_dir.to_s, force: true)
  end
else
  FileUtils.rm_f(tmp_rbs_dir)
  library "rbs"
end

target :app do
  collection_config "rbs_collection.steep.yaml"

  check "lib"
  ignore "lib/steep/shims"

  signature "sig"
  ignore_signature "sig/test"

  configure_code_diagnostics(D::Ruby.strict) do |hash|
  end

  if tmp_rbs_dir.directory?
    signature tmp_rbs_dir.to_s
  else
    library "rbs"
  end
end

target :test do
  collection_config "rbs_collection.steep.yaml"

  unreferenced!

  check "test"
  signature "sig/test"

  configure_code_diagnostics(D::Ruby.lenient)

  if tmp_rbs_dir.directory?
    signature tmp_rbs_dir.to_s
  else
    library "rbs"
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
steep-1.9.0.dev.2 Steepfile