Created
November 7, 2016 23:32
-
-
Save Samsinite/a5a4e699537179ef559d30b4d7b54f37 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/local/heroku/ruby/bin/ruby | |
# encoding: UTF-8 | |
# resolve bin path, ignoring symlinks | |
require "pathname" | |
bin_file = Pathname.new(__FILE__).realpath | |
# add locally vendored gems to libpath | |
gem_dir = File.expand_path("../../vendor/gems", bin_file) | |
Dir["#{gem_dir}/**/lib"].each do |libdir| | |
$:.unshift libdir | |
end | |
# add self to libpath | |
$:.unshift File.expand_path("../../lib", bin_file) | |
# inject any code in ~/.heroku/client over top | |
require "heroku/updater" | |
Heroku::Updater.inject_libpath | |
# start up the CLI | |
require "heroku/cli" | |
Heroku.user_agent = "heroku-toolbelt/#{Heroku::VERSION} (#{RUBY_PLATFORM}) ruby/#{RUBY_VERSION}" | |
Heroku::CLI.start(*ARGV) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment