Class: Opsk::Uncommited

Inherits:
Thor::Group
  • Object
show all
Includes:
Thorable, Thor::Actions
Defined in:
lib/opskeleton/uncommited.rb

Instance Method Summary collapse

Methods included from Thorable

#artifact, #artifact_path, #check_root, included, #machines, #meta, #name, #type_of

Instance Method Details

#uncommitedObject



48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
# File 'lib/opskeleton/uncommited.rb', line 48

def uncommited
  Dir["modules/*"].reject{|o| not File.directory?(o)}.each do |d|
    if File.exists?("#{d}/.git")
 begin
    cg = Opsk::Git.new(d,self)
    if cg.changed?
say "Listing changes for #{d}:\n\n"
cg.report
    end
 rescue => e 
    say "Failed to check uncommited under #{d} due to #{e}"
 end
    end
  end
end

#validateObject



43
44
45
# File 'lib/opskeleton/uncommited.rb', line 43

def validate
  check_root
end