lib/commit.rb in dev_tasks-1.0.11 vs lib/commit.rb in dev_tasks-1.0.12

- old
+ new

@@ -1,10 +1,10 @@ require_relative('./commandarray.rb') require_relative('./environment.rb') class Commit < CommandArray def update - if(Dir.exists?(".git")) + if(Dir.exists?(".git") && `git config --list`.include?('user.name=')) if(`git status`.include?('nothing to commit') || `git status`.include?('untracked files present')) # skip else if(File.exists?('commit.message') && File.read('commit.message').gsub(/\s+/, "").length > 0) self.add "git commit -a -v -m \"#{File.read('commit.message')}\"" \ No newline at end of file