Sha256: 50fa646c70e6c134746693a954998821d60881b67479c90c26005f5632d4fd2e

Contents?: true

Size: 1.05 KB

Versions: 4

Compression:

Stored size: 1.05 KB

Contents

#!/usr/bin/env rbx
# -*- ruby -*-

base = File.dirname(__FILE__)
require File.expand_path("../boot/fancy_ext", base)

# Use the bootstrapping code loader.
require File.expand_path("../boot/load", base)

do_retry = true
begin
  Fancy::CodeLoader.load_compiled_file File.expand_path("../lib/boot", base)

  # Remove the bootstrapping code loader
  bcl = Fancy.send :remove_const, :CodeLoader
  bcl.load_compiled_file File.expand_path("../lib/rbx/code_loader", base)

  # Initialize the load path
  Fancy::CodeLoader.push_loadpath File.expand_path("../lib", base)

  # Load compiler+eval support
  Fancy::CodeLoader.load_compiled_file File.expand_path("../lib/eval", base)

  # Run main
  Fancy::CodeLoader.load_compiled_file File.expand_path("../lib/main", base)

rescue RuntimeError => e
  if e.message =~ /File not found (.*)lib\/boot.fyc/
    if do_retry
      puts "Fancy hasn't been bootstrapped yet. Doing that now.\n\n"
      `cd #{base} && rbx -S rake clean && rbx -S rake`
      do_retry = false
      retry
    else
      raise e
    end
  else
    raise e
  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
fancy-0.3.3 bin/fancy
fancy-0.3.2 bin/fancy
fancy-0.3.1 bin/fancy
fancy-0.3.0 bin/fancy