Remove hidden defs references

This commit is contained in:
Douglas Eichelberger 2024-02-04 06:01:02 -08:00
parent a40fc0afd3
commit 07fad780de
4 changed files with 0 additions and 18 deletions

1
.gitignore vendored
View File

@ -21,7 +21,6 @@
/Library/Taps
/Library/PinnedTaps
/Library/Homebrew/.byebug_history
/Library/Homebrew/sorbet/rbi/hidden-definitions/errors.txt
# Ignore Bundler files
**/.bundle/bin

View File

@ -18,7 +18,6 @@ AllCops:
- "**/*.rbi"
Exclude:
- "Homebrew/sorbet/rbi/gems/**/*.rbi"
- "Homebrew/sorbet/rbi/hidden-definitions/*.rbi"
- "Homebrew/bin/*"
- "Homebrew/vendor/**/*"
- "Taps/*/*/vendor/**/*"

View File

@ -60,18 +60,6 @@ module Homebrew
safe_system "bundle", "exec", "tapioca", "gem", *tapioca_args
safe_system "bundle", "exec", "parlour"
safe_system({ "RUBYLIB" => "#{HOMEBREW_LIBRARY_PATH}/sorbet/hidden_definitions_hacks" },
"bundle", "exec", "srb", "rbi", "hidden-definitions")
# HACK: we'll phase out hidden-definitions soon
tmp_file = "sorbet/rbi/hidden-definitions/hidden.rbi.tmp"
orig_file = "sorbet/rbi/hidden-definitions/hidden.rbi"
File.open(tmp_file, "w") do |out_file|
File.foreach(orig_file) do |line|
out_file.puts line unless line.include?("def self.new(*args, **arg, &blk); end")
end
end
File.rename(tmp_file, orig_file)
if args.suggest_typed?
ohai "Bumping Sorbet `typed` sigils..."
# --sorbet needed because of https://github.com/Shopify/spoom/issues/488

View File

@ -1,4 +0,0 @@
# typed: strict
# frozen_string_literal: true
# This file intentionally left blank