pt-flow 0.1.1 → 0.1.2

Sign up to get free protection for your applications and to get access to all the features.
data/README.md CHANGED
@@ -18,10 +18,10 @@ Install the gem:
18
18
 
19
19
  ```bash
20
20
  $ flow start
21
- # shows lists of tasks, choosing one starts/assigns the task and checks out a new branch.
21
+ # shows lists of tasks - choosing one starts/assigns the task on pt and checks out a new branch.
22
22
 
23
23
  $ flow finish
24
- # pushes branch to origin, finishes task on pt and opens github on pull request page.
24
+ # pushes branch, finishes task on pt, and opens github new pull request page.
25
25
  # follow with cap staging deploy:migrations BRANCH=325325 etc...
26
26
  ```
27
27
 
@@ -33,5 +33,5 @@ $ git checkout 325325
33
33
  # run tests, review code etc...
34
34
 
35
35
  $ flow deliver
36
- # merges with master, pushes master to origin, deletes local/remote branch, delivers task on pt
36
+ # merges with master, pushes master branch, deletes local/remote branch, and delivers task on pt
37
37
  # follow with cap production deploy:migrations etc...
data/lib/pt-flow/ui.rb CHANGED
@@ -42,6 +42,19 @@ class PT::Flow::UI < PT::UI
42
42
  deliver_task(task)
43
43
  end
44
44
 
45
+ def cleanup
46
+ # Run from master
47
+ `git checkout master`
48
+
49
+ # Remove local fully merged branches
50
+ `git branch --merged master | grep -v 'master$' | xargs git branch -d`
51
+
52
+ # Update our list of remotes
53
+ `git fetch`
54
+ `git remote prune origin`
55
+ congrats('All clean!')
56
+ end
57
+
45
58
  def help
46
59
  if ARGV[0] && ARGV[0] != 'help'
47
60
  message("Command #{ARGV[0]} not recognized. Showing help.")
@@ -51,6 +64,7 @@ class PT::Flow::UI < PT::UI
51
64
  puts("flow start # start working on a story")
52
65
  puts("flow finish # finish a story and create a pull request")
53
66
  puts("flow deliver # merge current story branch and clean up")
67
+ puts("flow cleanup # deleted merged local branches and prune origin")
54
68
  end
55
69
 
56
70
  private
@@ -1,5 +1,5 @@
1
1
  module PT
2
2
  module Flow
3
- VERSION = "0.1.1"
3
+ VERSION = "0.1.2"
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: pt-flow
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.1
4
+ version: 0.1.2
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-10-04 00:00:00.000000000 Z
12
+ date: 2012-10-05 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: pt
16
- requirement: !ruby/object:Gem::Requirement
16
+ requirement: &70216886915660 !ruby/object:Gem::Requirement
17
17
  none: false
18
18
  requirements:
19
19
  - - ! '>='
@@ -21,12 +21,7 @@ dependencies:
21
21
  version: '0'
22
22
  type: :runtime
23
23
  prerelease: false
24
- version_requirements: !ruby/object:Gem::Requirement
25
- none: false
26
- requirements:
27
- - - ! '>='
28
- - !ruby/object:Gem::Version
29
- version: '0'
24
+ version_requirements: *70216886915660
30
25
  description: Some extra methods for the pt gem to use in our dev flow.
31
26
  email:
32
27
  - jens@balvig.com
@@ -59,7 +54,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
59
54
  version: '0'
60
55
  segments:
61
56
  - 0
62
- hash: 3502779640242885259
57
+ hash: -853934079676521156
63
58
  required_rubygems_version: !ruby/object:Gem::Requirement
64
59
  none: false
65
60
  requirements:
@@ -68,10 +63,10 @@ required_rubygems_version: !ruby/object:Gem::Requirement
68
63
  version: '0'
69
64
  segments:
70
65
  - 0
71
- hash: 3502779640242885259
66
+ hash: -853934079676521156
72
67
  requirements: []
73
68
  rubyforge_project:
74
- rubygems_version: 1.8.23
69
+ rubygems_version: 1.8.11
75
70
  signing_key:
76
71
  specification_version: 3
77
72
  summary: Some extra methods for the pt gem to use in our dev flow.