mirror of
https://github.com/sinatra/sinatra
synced 2023-03-27 23:18:01 -04:00
read gemspec in simulated github environment
This commit is contained in:
parent
be5a174158
commit
066345135e
1 changed files with 8 additions and 1 deletions
9
Rakefile
9
Rakefile
|
@ -17,9 +17,16 @@ end
|
||||||
|
|
||||||
# PACKAGING ============================================================
|
# PACKAGING ============================================================
|
||||||
|
|
||||||
|
# Load the gemspec using the same limitations as github
|
||||||
def spec
|
def spec
|
||||||
@spec ||=
|
@spec ||=
|
||||||
eval(File.read('sinatra.gemspec'))
|
begin
|
||||||
|
require 'rubygems/specification'
|
||||||
|
data = File.read('sinatra.gemspec')
|
||||||
|
spec = nil
|
||||||
|
Thread.new { spec = eval("$SAFE = 3\n#{data}") }.join
|
||||||
|
spec
|
||||||
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
def package(ext='')
|
def package(ext='')
|
||||||
|
|
Loading…
Add table
Reference in a new issue