opskeleton 0.9.7 → 0.9.8

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: e88ceb8435b3382bf526d1060284872353417b39
4
- data.tar.gz: 9b4775baf6d6d1bc74a0cb314d26a81b7691dc5f
3
+ metadata.gz: 26d32885b62a88bd0bd3fd0efe5488a7354f5c80
4
+ data.tar.gz: 55c592d0a60a47ee379c312f7def6321254efed0
5
5
  SHA512:
6
- metadata.gz: 10469a0fafe1b3e729397dba4a18a4184c91a4daae58e774f1b5efd032f71e6a13dd11a4f769988feb41d2b211c218f76a5240b3b627854283b97d23604e19bd
7
- data.tar.gz: 6020fc413566adc7df5d681a071719c6c07ec87271c93438abde94c8949deaa2e4c106d1e387332c7d017a818852ed04746f1fd9431dbf621fba1c91267db624
6
+ metadata.gz: 01e7c53f0f89763dd0ff559fd62488a3ca6eab03c7b5872d0c86636b89c20ad2fc3cbc093662279481c0ead19432cbd205a5436e9d4eddc24fcf79bf50822f48
7
+ data.tar.gz: 19f77f77c16957c07db7d24c033fcce43ca0bb6dafd7594ca5cdef4527200613009d31f876e361e479531b0747e76ff218ae9d8283a10df69a92a3205b8dd666
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- opskeleton (0.9.7)
4
+ opskeleton (0.9.8)
5
5
  aws-sdk (~> 2)
6
6
  bintray_deploy
7
7
  git
@@ -15,16 +15,20 @@ module Opsk
15
15
  def_delegator :@g, :pull, :pull
16
16
 
17
17
  def changed?
18
- git_run('status').include?('modified')
18
+ res = git_run('status')
19
+ %w(modified deleted untracked).detect{|c| res.include?(c)}
19
20
  end
20
21
 
21
22
  def report
22
- %i(changed added untracked).each do |state|
23
- @thor.say "#{state} files:\n\n"
24
- @g.status.send(state).each do |k,v|
25
- @thor.say "- #{k}"
23
+ %i(changed added untracked deleted).each do |state|
24
+ res = @g.status.send(state)
25
+ if(res.length > 0)
26
+ @thor.say "#{state} files:\n\n"
27
+ res.each do |k,v|
28
+ @thor.say "- #{k}"
29
+ end
30
+ @thor.say "\n"
26
31
  end
27
- @thor.say "\n"
28
32
  end
29
33
  end
30
34
 
@@ -1,42 +1,6 @@
1
1
 
2
2
 
3
3
  module Opsk
4
- class CommitGit
5
- def initialize(d,options,thor)
6
- @g = Git.init(d)
7
- @options = options
8
- @thor = thor
9
- end
10
-
11
- def changed?
12
- @g.status.changed.keys.length > 0
13
- end
14
-
15
- def report
16
- %i(changed added untracked).each do |state|
17
- @thor.say "#{state} files:\n\n"
18
- @g.status.send(state).each do |k,v|
19
- @thor.say "- #{k}"
20
- end
21
- @thor.say "\n"
22
- end
23
- end
24
-
25
- def master_commit(d)
26
- resp = @thor.yes? "Commit the changes under #{d}? (y/n)" unless @options['all']
27
- if(@options['all'] or resp)
28
- @g.checkout('master')
29
- if @options['message']
30
- @g.commit_all(@options['message'])
31
- else
32
- @thor.say 'Commit message:'
33
- @g.commit_all(STDIN.gets.chomp)
34
- end
35
- end
36
-
37
- end
38
- end
39
-
40
4
  class Uncommited < Thor::Group
41
5
  include Thorable, Thor::Actions
42
6
 
@@ -44,7 +8,6 @@ module Opsk
44
8
  check_root
45
9
  end
46
10
 
47
-
48
11
  def uncommited
49
12
  Dir["modules/*"].reject{|o| not File.directory?(o)}.each do |d|
50
13
  if File.exists?("#{d}/.git")
@@ -1,3 +1,3 @@
1
1
  module Opskeleton
2
- VERSION = '0.9.7'
2
+ VERSION = '0.9.8'
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: opskeleton
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.9.7
4
+ version: 0.9.8
5
5
  platform: ruby
6
6
  authors:
7
7
  - narkisr