bones-git 1.2.5 → 1.3.0

Sign up to get free protection for your applications and to get access to all the features.
@@ -1,3 +1,8 @@
1
+ == 1.3.0 / 2012-04-04
2
+
3
+ Enhancements
4
+ - shell out to `git ls-files` to generate the project manifest
5
+
1
6
  == 1.2.5 / 2012-01-26
2
7
 
3
8
  Bug Fixes
@@ -88,6 +88,5 @@ module Bones::App::Git
88
88
  "http://github.com/#{user}/#{name}"
89
89
  end
90
90
 
91
- end # module Bones::App::Git
91
+ end # Bones::App::Git
92
92
 
93
- # EOF
@@ -5,11 +5,13 @@ module Bones::Plugins::Git
5
5
  include ::Bones::Helpers
6
6
  extend self
7
7
 
8
- def post_load
8
+ def initialize_git
9
9
  have?(:git) {
10
10
  Dir.entries(Dir.pwd).include?('.git') and
11
11
  quiet { system("git --version") }
12
12
  }
13
+
14
+ Bones::Plugins::Gem.extend GemOverrides if have? :git
13
15
  end
14
16
 
15
17
  def define_tasks
@@ -23,12 +25,12 @@ module Bones::Plugins::Git
23
25
 
24
26
  desc 'Show tags from the git repository'
25
27
  task :tags => 'git:prereqs' do |t|
26
- puts Git.open('.').tags.map {|t| t.name}.reverse
28
+ puts Git.open('.').tags.map {|tg| tg.name}.reverse
27
29
  end
28
30
 
29
31
  desc 'Show all log messages since the last release'
30
32
  task :changes => 'git:prereqs' do |t|
31
- tag = Git.open('.').tags.map {|t| t.name}.last
33
+ tag = Git.open('.').tags.map {|tg| tg.name}.last
32
34
  range = tag ? "#{tag}..HEAD" : ''
33
35
  system "git log --oneline #{range}"
34
36
  end
@@ -62,7 +64,7 @@ module Bones::Plugins::Git
62
64
  git = Git.open '.'
63
65
  tag = "%s-%s" % [config.name, v]
64
66
 
65
- unless git.tags.map {|t| t.name}.include? tag
67
+ unless git.tags.map {|tg| tg.name}.include? tag
66
68
  puts "Tag '#{tag}' does not exist."
67
69
  break
68
70
  end
@@ -95,5 +97,20 @@ module Bones::Plugins::Git
95
97
  task 'gem:release' => 'git:create_tag'
96
98
  end
97
99
 
98
- end # module Bones::Plugins::Git
100
+ # Override the `manifest` method in the Gem plugin so that the list of
101
+ # filese to package is provided from git and its include / exclude rules.
102
+ #
103
+ module GemOverrides
104
+
105
+ # This method uses the `git ls-files` command to list the files that
106
+ # should be included in the packaging process for the project.
107
+ #
108
+ # Returns an array of filenames as Strings.
109
+ #
110
+ def manifest
111
+ %x{git ls-files}.split
112
+ end
113
+ end
114
+
115
+ end # Bones::Plugins::Git
99
116
 
@@ -1 +1 @@
1
- 1.2.5
1
+ 1.3.0
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: bones-git
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.2.5
4
+ version: 1.3.0
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -9,11 +9,11 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2012-01-26 00:00:00.000000000Z
12
+ date: 2012-04-05 00:00:00.000000000Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: bones
16
- requirement: &2166794680 !ruby/object:Gem::Requirement
16
+ requirement: &2158986240 !ruby/object:Gem::Requirement
17
17
  none: false
18
18
  requirements:
19
19
  - - ! '>='
@@ -21,10 +21,10 @@ dependencies:
21
21
  version: '3.6'
22
22
  type: :runtime
23
23
  prerelease: false
24
- version_requirements: *2166794680
24
+ version_requirements: *2158986240
25
25
  - !ruby/object:Gem::Dependency
26
26
  name: git
27
- requirement: &2166794240 !ruby/object:Gem::Requirement
27
+ requirement: &2158985660 !ruby/object:Gem::Requirement
28
28
  none: false
29
29
  requirements:
30
30
  - - ! '>='
@@ -32,10 +32,10 @@ dependencies:
32
32
  version: 1.2.5
33
33
  type: :runtime
34
34
  prerelease: false
35
- version_requirements: *2166794240
35
+ version_requirements: *2158985660
36
36
  - !ruby/object:Gem::Dependency
37
37
  name: bones
38
- requirement: &2166793660 !ruby/object:Gem::Requirement
38
+ requirement: &2158985080 !ruby/object:Gem::Requirement
39
39
  none: false
40
40
  requirements:
41
41
  - - ! '>='
@@ -43,7 +43,7 @@ dependencies:
43
43
  version: 3.7.2
44
44
  type: :development
45
45
  prerelease: false
46
- version_requirements: *2166793660
46
+ version_requirements: *2158985080
47
47
  description: ! 'The git package for Mr Bones provides tasks to incorporate git actions
48
48
  into
49
49