agile_check_in 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.
- data/bin/cic +4 -0
- data/lib/agile_check_in/version.rb +1 -1
- data/lib/agile_check_in.rb +12 -6
- metadata +11 -3
data/bin/cic
ADDED
data/lib/agile_check_in.rb
CHANGED
@@ -3,10 +3,10 @@ require "agile_check_in/git"
|
|
3
3
|
require "yaml"
|
4
4
|
|
5
5
|
module AgileCheckIn
|
6
|
-
def self.incremental
|
6
|
+
def self.incremental options={}
|
7
7
|
pair_names = ""
|
8
8
|
story_number = ""
|
9
|
-
|
9
|
+
|
10
10
|
if Git.has_local_changes?
|
11
11
|
history_file = '/tmp/agile_check_in_history.yml'
|
12
12
|
if File.exists?(history_file)
|
@@ -22,7 +22,7 @@ module AgileCheckIn
|
|
22
22
|
end until !pair_names.empty?
|
23
23
|
|
24
24
|
begin
|
25
|
-
$stdout.write "Story number [#{story_number}]: "
|
25
|
+
$stdout.write "Story number (NA) [#{story_number}]: "
|
26
26
|
input = $stdin.gets.strip
|
27
27
|
story_number = input unless input.empty?
|
28
28
|
end until !story_number.empty?
|
@@ -31,10 +31,16 @@ module AgileCheckIn
|
|
31
31
|
YAML.dump({ "shove" => { "pair" => pair_names, "story" => story_number } }, out)
|
32
32
|
end
|
33
33
|
|
34
|
-
|
34
|
+
if story_number.delete("/").downcase == "na"
|
35
|
+
commit_message = ""
|
36
|
+
else
|
37
|
+
commit_message = "[##{story_number}] "
|
38
|
+
end
|
39
|
+
|
40
|
+
author = "#{pair_names} <agile_check_in@#{`hostname`}>"
|
35
41
|
|
36
|
-
system("git add -A")
|
37
|
-
system("EDITOR=vim git commit -e -m '#{commit_message}'")
|
42
|
+
system("git add -A") if options[:add]
|
43
|
+
system("EDITOR=vim git commit --author='#{author}' -e -m '#{commit_message}'")
|
38
44
|
else
|
39
45
|
puts "No local changes to commit."
|
40
46
|
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: agile_check_in
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.4
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -10,7 +10,7 @@ authors:
|
|
10
10
|
autorequire:
|
11
11
|
bindir: bin
|
12
12
|
cert_chain: []
|
13
|
-
date: 2012-
|
13
|
+
date: 2012-06-28 00:00:00.000000000 Z
|
14
14
|
dependencies: []
|
15
15
|
description: Easy check in
|
16
16
|
email:
|
@@ -18,6 +18,7 @@ email:
|
|
18
18
|
- rsliter@thoughtworks.com
|
19
19
|
executables:
|
20
20
|
- ci
|
21
|
+
- cic
|
21
22
|
- cii
|
22
23
|
extensions: []
|
23
24
|
extra_rdoc_files: []
|
@@ -29,6 +30,7 @@ files:
|
|
29
30
|
- Rakefile
|
30
31
|
- agile_check_in.gemspec
|
31
32
|
- bin/ci
|
33
|
+
- bin/cic
|
32
34
|
- bin/cii
|
33
35
|
- lib/agile_check_in.rb
|
34
36
|
- lib/agile_check_in/git.rb
|
@@ -45,15 +47,21 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
45
47
|
- - ! '>='
|
46
48
|
- !ruby/object:Gem::Version
|
47
49
|
version: '0'
|
50
|
+
segments:
|
51
|
+
- 0
|
52
|
+
hash: -2628721004049552309
|
48
53
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
49
54
|
none: false
|
50
55
|
requirements:
|
51
56
|
- - ! '>='
|
52
57
|
- !ruby/object:Gem::Version
|
53
58
|
version: '0'
|
59
|
+
segments:
|
60
|
+
- 0
|
61
|
+
hash: -2628721004049552309
|
54
62
|
requirements: []
|
55
63
|
rubyforge_project:
|
56
|
-
rubygems_version: 1.8.
|
64
|
+
rubygems_version: 1.8.11
|
57
65
|
signing_key:
|
58
66
|
specification_version: 3
|
59
67
|
summary: Easy check in
|