homebrew-core/Formula/rbenv-gem-rehash.rb
Steven Peters a649d9b4ec Use .diff instead of .patch for github commit sourced patches
This modifies multiple formulae in a single commit, replacing
the patch suffix with diff per Homebrew/homebrew#28315. I used the following
command:
~~~
sed -i -e 's@patch"$@diff"@' `grep -rlI 'commit.*patch"$' .`
~~~
The patch shasums are then computed using:
~~~
brew fetch --build-from-source `git st | sed -e 's@^ M@@'`
~~~
and manually updated.

Fixes Homebrew/homebrew#28315.
Fixes Homebrew/homebrew#28335.
Closes Homebrew/homebrew#28339.

Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2014-04-11 20:53:22 -05:00

29 lines
1 KiB
Ruby

require 'formula'
class RbenvGemRehash < Formula
homepage 'https://github.com/sstephenson/rbenv-gem-rehash'
url 'https://github.com/sstephenson/rbenv-gem-rehash/archive/v1.0.0.tar.gz'
sha1 '40962ef5cda77ff46c0d0a3f262076b58088dd57'
depends_on 'rbenv'
# Fixes issues with Homebrew-managed git-etc alpha.
patch do
url "https://github.com/sstephenson/rbenv-gem-rehash/commit/0756890cfd9c7bbbdde38560fe81626a0c5769bd.diff"
sha1 "17877b728eda6eaddc199bcd5935fcea757a1c63"
end
def install
prefix.install Dir['*']
end
def caveats; <<-EOS.undent
If the GEM_PATH environment variable is undefined, rbenv-gem-rehash must
first execute the gem env gempath command to retrieve RubyGems' default path
so that it can can append to the path rather than override it. This can take
a while--from a few hundred milliseconds on MRI to several seconds on
JRuby--so the default path for the current Ruby version is cached to the
filesystem the first time it is retrieved.
EOS
end
end