Class: LegacyPatch Private

Inherits:
ExternalPatch show all
Defined in:
Library/Homebrew/patch.rb

Overview

This class is part of a private API. You should avoid using this class if possible, as it may be removed or be changed in the future.

A legacy patch.

Legacy patches have no checksum and are not cached.

Instance Attribute Summary

Attributes inherited from ExternalPatch

#resource, #strip

Instance Method Summary collapse

Methods inherited from ExternalPatch

#external?, #inspect, #owner=

Constructor Details

#initialize(strip, url) ⇒ LegacyPatch

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

Returns a new instance of LegacyPatch.


194
195
196
197
198
199
# File 'Library/Homebrew/patch.rb', line 194

def initialize(strip, url)
  odeprecated "legacy patches", "'patch do' blocks"
  super(strip)
  resource.url(url)
  resource.download_strategy = CurlDownloadStrategy
end

Instance Method Details

#applyObject

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.


210
211
212
213
214
# File 'Library/Homebrew/patch.rb', line 210

def apply
  super
ensure
  clear_cache
end

#fetchObject

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.


201
202
203
204
# File 'Library/Homebrew/patch.rb', line 201

def fetch
  clear_cache
  super
end

#verify_download_integrity(_fn) ⇒ Object

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.


206
207
208
# File 'Library/Homebrew/patch.rb', line 206

def verify_download_integrity(_fn)
  # no-op
end