greenhouse 0.0.3 → 0.0.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 275b120e3a88469a7c59a1ef80c34e8e53684599
4
- data.tar.gz: 3e5d0d6545c76c9d127252c20616277ccd338c9d
3
+ metadata.gz: a134de22c868aab5eb02a87a98f2d673a8d73487
4
+ data.tar.gz: e51793dd35718de74464e70b9e17715bfda2ded0
5
5
  SHA512:
6
- metadata.gz: b821db4b17049bc511b15af85f48a7810d22b45b8578aeddb47baf89b30ea54f99f88e4de727875639a322f40640477399cb6e58d107bb22fbf1c852070aca60
7
- data.tar.gz: 15da3ce7567ce8ac67789d9f839dd202649bbef426c6d3a29571ebadf4286d4e60d27c02bc7d227e81b7a94d7efd8b490c9621e30cee25dec56ab8881395e05f
6
+ metadata.gz: 5cb9fab942476db9870564a19cd4b0b9908ec70308835f5c21efcf41b5bacaa2a2424b6f6abaa5e50968bc00aa1d00b8e22cc162a51786e8a01e76c2ae80fa95
7
+ data.tar.gz: 9b5ab3cb8db6b7b55be8c00b181046d2952e514ee404d27a54174a20c6257433794f5f8e76718f8479069bbea629a7dba9b4159e36cd59608f76fbfce4a0096c
@@ -56,9 +56,18 @@ module Greenhouse
56
56
  binary
57
57
  end
58
58
 
59
+ def self.version=(ver)
60
+ @version = ver
61
+ end
62
+
63
+ def self.version
64
+ @version ||= VERSION
65
+ end
66
+
59
67
  def self.usage
60
68
  puts <<USAGE
61
- usage: #{command_name} #{valid_arguments.to_s} <command> [<args>]
69
+ #{binary} v#{version}
70
+ usage: #{binary} #{valid_arguments.to_s} <command> [<args>]
62
71
 
63
72
  The available greenhouse commands are:
64
73
  USAGE
@@ -69,7 +78,7 @@ USAGE
69
78
  end
70
79
 
71
80
  puts
72
- puts "See `#{command_name} help <command>` for more information on a specific command."
81
+ puts "See `#{binary} help <command>` for more information on a specific command."
73
82
  end
74
83
 
75
84
  def self.start
@@ -8,7 +8,7 @@ module Greenhouse
8
8
 
9
9
  class << self
10
10
  def usage
11
- puts "usage: #{::Greenhouse::CLI.command_name} #{command_name} <name> #{valid_arguments.to_s}"
11
+ puts "usage: #{::Greenhouse::CLI::binary} #{command_name} <name> #{valid_arguments.to_s}"
12
12
  end
13
13
  end
14
14
 
@@ -21,7 +21,7 @@ module Greenhouse
21
21
  projects_directory = arguments.first.key
22
22
  if File.exists?(projects_directory)
23
23
  STDERR.puts "Directory already exists: #{projects_directory}"
24
- STDERR.puts "You can try running `#{::Greenhouse::CLI.command_name} init` from inside the directory."
24
+ STDERR.puts "You can try running `#{::Greenhouse::CLI::binary} init` from inside the directory."
25
25
  exit 1
26
26
  end
27
27
 
@@ -32,10 +32,7 @@ module Greenhouse
32
32
  exit 1
33
33
  end
34
34
 
35
- exec "cd #{projects_directory}; greenhouse init"
36
- #Dir.chdir(projects_directory) do
37
- # Init.run
38
- #end
35
+ exec "cd #{projects_directory}; #{::Greenhouse::CLI::binary} init"
39
36
  end
40
37
  end
41
38
  end
@@ -36,7 +36,7 @@ module Greenhouse
36
36
  # TODO delete any comments immediately preceding the filename
37
37
  deleted = super(select { |f| f.file == filename}.first)
38
38
  @ignore_file.ignored.each do |ignored|
39
- next if ignored.line < deleted.line
39
+ next if ignored.line <= deleted.line
40
40
  ignored.line -= 1
41
41
  end
42
42
  line = @ignore_file.lines.slice!(deleted.line,1)
@@ -25,7 +25,7 @@ module Greenhouse
25
25
  def delete(key)
26
26
  del = super(key)
27
27
  @procfile.processes.each do |key,process|
28
- next if process.line < del.line
28
+ next if process.line <= del.line
29
29
  process.line -= 1
30
30
  end
31
31
  line = @procfile.lines.slice!(del.line,1)
@@ -1,8 +1,13 @@
1
1
  module Greenhouse
2
- VERSION = "0.0.3"
2
+ VERSION = "0.0.4"
3
3
  end
4
4
 
5
5
  __END__
6
+ 0.0.4:
7
+ * Fixed bug with new not referencing the active binary
8
+ * Fixed a couple off by one errors in resource files
9
+ * Printing version in binary usage output
10
+
6
11
  0.0.3:
7
12
  * Ability to set the CLI binary name
8
13
  * Broke out Forth Rail specific stuff into it's own binary `forthrail`
data/lib/greenhouse.rb CHANGED
@@ -1,6 +1,7 @@
1
1
  require 'bundler'
2
2
  require 'rake'
3
3
  require 'active_support/inflector'
4
+ require 'greenhouse/version'
4
5
  require 'greenhouse/resources'
5
6
  require 'greenhouse/projects'
6
7
  require 'greenhouse/scripts'
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: greenhouse
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.3
4
+ version: 0.0.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Mark Rebec