class Tara::Shim

@private

Public Class Methods

new(command) click to toggle source
# File lib/tara/shim.rb, line 6
def initialize(command)
  @command = command
end

Public Instance Methods

write(io) click to toggle source
# File lib/tara/shim.rb, line 10
def write(io)
  io.puts(script_template)
end

Private Instance Methods

script_template() click to toggle source
# File lib/tara/shim.rb, line 16
    def script_template
      <<-EOH.gsub(/^\s+/, '')
        #!/bin/bash
        set -e
        SELF_DIR=$(dirname "$0")
        export BUNDLE_GEMFILE="$SELF_DIR/lib/vendor/Gemfile"
        unset BUNDLE_IGNORE_CONFIG
        exec "$SELF_DIR/lib/ruby/bin/ruby" -rbundler/setup #{@command}
      EOH
    end