Sha256: e7a6ac398d897fc0b8ff2c059eb218695ef5be9638ed2f327fe7826c5dbe701d

Contents?: true

Size: 700 Bytes

Versions: 1

Compression:

Stored size: 700 Bytes

Contents

class Add < Array
	def update
		if(File.exists?('.git') && File.exists?('.gitignore'))
			add 'git add --all' 
		else
			if(defined?(SOURCE))
				if(File.exists?('.svn'))
					SOURCE.each{|f|
						if(File.exists?(f))
	                        status=Command.output("svn status #{f}")
	                        if(status.length==0 || status.include?('was not found'))
								puts "svn add #{f} --parents"
								add "svn add #{f} --parents"
							else
								puts "#{status}"
							end
						end
					}
				end
				if(File.exists?('.git'))
					SOURCE.each{|f|
						add "git add #{f} -v" if `git status #{f}`.include?('untracked')
					}
				end
			end
		end
	end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
dev-2.0.110 lib/commands/add.rb