diff --git a/Gemfile.lock b/Gemfile.lock index 9fccbe0..46f061a 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -1,7 +1,7 @@ PATH remote: . specs: - turbulence (1.2.2) + turbulence (1.2.3) flog (~> 4.1) json (>= 1.4.6) launchy (>= 2.0.0) diff --git a/bin/bule b/bin/bule index d334948..4d2aa2a 100755 --- a/bin/bule +++ b/bin/bule @@ -1,23 +1,14 @@ -#!/usr/bin/env ruby_executable_hooks -# -# This file was generated by RubyGems. -# -# The application 'turbulence' is installed as part of a gem, and -# this file is here to facilitate running it. -# +#!/usr/bin/env ruby +require 'turbulence' +require 'turbulence/checks_environment' -require 'rubygems' +cli = Turbulence::CommandLineInterface.new(ARGV) -version = ">= 0" - -if ARGV.first - str = ARGV.first - str = str.dup.force_encoding("BINARY") if str.respond_to? :force_encoding - if str =~ /\A_(.*)_\z/ - version = $1 - ARGV.shift - end +unless Turbulence::ChecksEnvironment.scm_repo?(Dir.pwd) + STDERR.puts "Turbulence could not calculate metrics, as we could not find a repository in the current directory." + STDERR.puts "Please run bule from inside a repository." + exit end -gem 'turbulence', version -load Gem.bin_path('turbulence', 'bule', version) +cli.generate_bundle +cli.open_bundle diff --git a/lib/turbulence/version.rb b/lib/turbulence/version.rb index 4392764..d1187f6 100644 --- a/lib/turbulence/version.rb +++ b/lib/turbulence/version.rb @@ -1,3 +1,3 @@ class Turbulence - VERSION = "1.2.2" + VERSION = "1.2.3" end