mirror of
https://github.com/internetee/registry.git
synced 2025-05-16 09:27:19 +02:00
parent
666ba69456
commit
a882eb2df4
2 changed files with 12 additions and 12 deletions
|
@ -1,4 +1,8 @@
|
||||||
#!/usr/bin/env ruby
|
#!/usr/bin/env ruby
|
||||||
|
begin
|
||||||
|
load File.expand_path("../spring", __FILE__)
|
||||||
|
rescue LoadError
|
||||||
|
end
|
||||||
#
|
#
|
||||||
# This file was generated by Bundler.
|
# This file was generated by Bundler.
|
||||||
#
|
#
|
||||||
|
|
20
bin/spring
20
bin/spring
|
@ -1,19 +1,15 @@
|
||||||
#!/usr/bin/env ruby
|
#!/usr/bin/env ruby
|
||||||
|
|
||||||
# This file loads spring without using Bundler, in order to be fast
|
# This file loads spring without using Bundler, in order to be fast.
|
||||||
# It gets overwritten when you run the `spring binstub` command
|
# It gets overwritten when you run the `spring binstub` command.
|
||||||
|
|
||||||
unless defined?(Spring)
|
unless defined?(Spring)
|
||||||
require 'rubygems'
|
require "rubygems"
|
||||||
require 'bundler'
|
require "bundler"
|
||||||
|
|
||||||
match = Bundler.default_lockfile.read.match(/^GEM$.*?^ spring \((.*?)\)$.*?^$/m)
|
if match = Bundler.default_lockfile.read.match(/^GEM$.*?^ (?: )*spring \((.*?)\)$.*?^$/m)
|
||||||
if match
|
Gem.paths = { "GEM_PATH" => [Bundler.bundle_path.to_s, *Gem.path].uniq }
|
||||||
ENV['GEM_PATH'] = ([Bundler.bundle_path.to_s] + Gem.path).join(File::PATH_SEPARATOR)
|
gem "spring", match[1]
|
||||||
ENV['GEM_HOME'] = nil
|
require "spring/binstub"
|
||||||
Gem.paths = ENV
|
|
||||||
|
|
||||||
gem 'spring', match[1]
|
|
||||||
require 'spring/binstub'
|
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue