gitty 0.4.3 → 0.4.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.
data/Rakefile CHANGED
@@ -1,29 +1,7 @@
1
- require 'rubygems'
2
- require 'rake'
3
-
4
- begin
5
- require 'jeweler'
6
- Jeweler::Tasks.new do |gem|
7
- gem.name = "gitty"
8
- gem.summary = %Q{Unobtrusively extend git}
9
- gem.description = %Q{Unobtrusively extend git}
10
- gem.email = "timcharper@gmail.com"
11
- gem.homepage = "http://github.com/timcharper/gitty"
12
- gem.authors = ["Tim Harper"]
13
- gem.files = Dir['lib/**/*.rb'] + Dir['assets/**/*'] + ['bin/git-hook'] + Dir['cucumber/**/*'] + Dir['spec/**/*'] + %w[cucumber.yml Rakefile README.textile LICENSE]
14
- # gem.executables << 'git-hook'/
15
- end
16
- Jeweler::GemcutterTasks.new
17
- rescue LoadError
18
- puts "Jeweler (or a dependency) not available. Install it with: gem install jeweler"
19
- end
20
-
21
1
  require 'rake/rdoctask'
22
2
  Rake::RDocTask.new do |rdoc|
23
- version = File.exist?('VERSION') ? File.read('VERSION') : ""
24
-
25
3
  rdoc.rdoc_dir = 'rdoc'
26
- rdoc.title = "gitty #{version}"
4
+ rdoc.title = "gitty #{File.read('VERSION').chomp}"
27
5
  rdoc.rdoc_files.include('README*')
28
6
  rdoc.rdoc_files.include('lib/**/*.rb')
29
7
  end
@@ -23,18 +23,18 @@ class Gitty::HookCommand::List < Gitty::Runner
23
23
  end
24
24
 
25
25
  def show_local_or_shared_hooks(which)
26
- hooks = all_hooks.select { |h| h.install_kind == which.to_sym }
27
- puts "#{which}:\n#{listify(hooks)}\n\n"
26
+ hook_names = all_hooks.select { |h| h.install_kind == which.to_sym }.map(&:name)
27
+ puts "#{which}:\n#{listify(hook_names)}\n\n"
28
28
  end
29
29
 
30
30
  def listify(hooks)
31
- hooks.map { |h| "- #{h.name} #{h.inspect}" }.join("\n")
31
+ hooks.map { |h| "- #{h}" }.join("\n")
32
32
  end
33
33
 
34
34
  def show_uninstalled_hooks
35
- available_hooks = all_hooks.select { |h| ! h.installed? }
36
- installed_hooks = all_hooks.select { |h| h.installed? }
37
- uninstalled_hooks = available_hooks.reject { |h| installed_hooks.name == h.name }
35
+ available_hook_names = all_hooks.select { |h| ! h.installed? }.map(&:name)
36
+ installed_hook_names = all_hooks.select { |h| h.installed? }.map(&:name)
37
+ uninstalled_hooks = (available_hook_names - installed_hook_names).sort
38
38
  puts "uninstalled:\n#{listify(uninstalled_hooks)}\n\n"
39
39
  end
40
40
 
@@ -29,6 +29,8 @@ class Gitty::HookCommand::Publish < Gitty::Runner
29
29
  super
30
30
  if options[:message].nil?
31
31
  puts option_parser
32
+ puts "A message is required"
33
+ exit 1
32
34
  end
33
35
  end
34
36
  end
data/spec/spec_helper.rb CHANGED
@@ -1,7 +1,5 @@
1
- require 'rubygems'
2
- require 'bundler'
3
- Bundler.setup
4
1
  require File.dirname(__FILE__) + "/../lib/gitty"
2
+ require 'rubygems'
5
3
  require "spec"
6
4
  SPEC_PATH = Pathname.new(File.dirname(__FILE__))
7
5
  require SPEC_PATH + "../features/support/sandbox_world.rb"
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: gitty
3
3
  version: !ruby/object:Gem::Version
4
- hash: 9
4
+ hash: 7
5
5
  prerelease: false
6
6
  segments:
7
7
  - 0
8
8
  - 4
9
- - 3
10
- version: 0.4.3
9
+ - 4
10
+ version: 0.4.4
11
11
  platform: ruby
12
12
  authors:
13
13
  - Tim Harper
@@ -15,40 +15,21 @@ autorequire:
15
15
  bindir: bin
16
16
  cert_chain: []
17
17
 
18
- date: 2010-05-19 00:00:00 -06:00
18
+ date: 2010-09-20 00:00:00 -06:00
19
19
  default_executable:
20
20
  dependencies: []
21
21
 
22
22
  description: Unobtrusively extend git
23
23
  email: timcharper@gmail.com
24
24
  executables:
25
- - cucumber
26
25
  - git-hook
27
- - spec
28
26
  extensions: []
29
27
 
30
28
  extra_rdoc_files:
31
29
  - LICENSE
32
30
  - README.textile
33
31
  files:
34
- - LICENSE
35
- - README.textile
36
- - Rakefile
37
- - assets/helpers/git-cleanup-branches
38
- - assets/helpers/git-strip-new-whitespace
39
- - assets/helpers/git-submodule-helper
40
- - assets/helpers/git-trash
41
- - assets/helpers/git-when-introduced
42
- - assets/helpers/hookd_wrapper
43
- - assets/helpers/update-shared-hooks
44
- - assets/hooks/auto-submodules
45
- - assets/hooks/clean-patches
46
- - assets/hooks/git-prevent-messy-rebase
47
- - assets/hooks/nocommit
48
- - bin/git-hook
49
- - cucumber.yml
50
32
  - lib/ext.rb
51
- - lib/gitty.rb
52
33
  - lib/gitty/commands/init.rb
53
34
  - lib/gitty/commands/install.rb
54
35
  - lib/gitty/commands/list.rb
@@ -61,21 +42,36 @@ files:
61
42
  - lib/gitty/hook.rb
62
43
  - lib/gitty/hook_command.rb
63
44
  - lib/gitty/runner.rb
45
+ - lib/gitty.rb
64
46
  - lib/string.rb
47
+ - assets/helpers/git-cleanup-branches
48
+ - assets/helpers/git-strip-new-whitespace
49
+ - assets/helpers/git-submodule-helper
50
+ - assets/helpers/git-trash
51
+ - assets/helpers/git-when-introduced
52
+ - assets/helpers/hookd_wrapper
53
+ - assets/helpers/update-shared-hooks
54
+ - assets/hooks/auto-submodules
55
+ - assets/hooks/clean-patches
56
+ - assets/hooks/git-prevent-messy-rebase
57
+ - assets/hooks/nocommit
58
+ - bin/git-hook
65
59
  - spec/gitty/hook_spec.rb
66
60
  - spec/gitty_spec.rb
67
61
  - spec/spec.opts
68
62
  - spec/spec_helper.rb
69
63
  - spec/support/constants.rb
70
- - bin/cucumber
71
- - bin/spec
64
+ - cucumber.yml
65
+ - Rakefile
66
+ - README.textile
67
+ - LICENSE
72
68
  has_rdoc: true
73
69
  homepage: http://github.com/timcharper/gitty
74
70
  licenses: []
75
71
 
76
72
  post_install_message:
77
- rdoc_options:
78
- - --charset=UTF-8
73
+ rdoc_options: []
74
+
79
75
  require_paths:
80
76
  - lib
81
77
  required_ruby_version: !ruby/object:Gem::Requirement
data/bin/cucumber DELETED
@@ -1 +0,0 @@
1
- exec bundle exec cucumber "$*"
data/bin/spec DELETED
@@ -1 +0,0 @@
1
- exec bundle exec spec "$*"