Sha256: 0dd72a618d4b584f01426c49cf8111cd23c9d874b2474deb89d01f5976fa6661
Contents?: true
Size: 576 Bytes
Versions: 86
Compression:
Stored size: 576 Bytes
Contents
class Commit < Array def initialize if(Dir.exists?(".git")) if(!`git status`.include?('nothing to commit') || `git status`.include?('untracked files present')) if(File.exists?('commit.message') && File.read('commit.message').gsub(/\s+/, "").length > 0) self.add "git commit -a -v -m \"#{File.read('commit.message')}\"" self.add "<%File.open('commit.message','w'){|f|f.write('')}%>" else self.add 'git commit -a -v -m "commit all"' end end end end def add command self << command if(!include?(command)) end end
Version data entries
86 entries across 86 versions & 1 rubygems
Version | Path |
---|---|
dev_tasks-0.0.13 | lib/commit.rb |
dev_tasks-0.0.12 | lib/commit.rb |
dev_tasks-0.0.11 | lib/commit.rb |
dev_tasks-0.0.10 | lib/commit.rb |
dev_tasks-0.0.9 | lib/commit.rb |
dev_tasks-0.0.8 | lib/commit.rb |