Sha256: ae292db2bad964b2cbee3b037fd054f41ad5e3733a23186a5c786bf36976537d
Contents?: true
Size: 506 Bytes
Versions: 2
Compression:
Stored size: 506 Bytes
Contents
#require_relative('./commandarray.rb') require_relative('./environment.rb') require 'time' class Pull < Array#< CommandArray def update if(Environment.scm=='git' && Environment.scm_origin.length > 0 && `git config --list`.include?('user.name=')) if(Timer.elapsed_exceeds?("last_pull",60*60*2)) #if(Timer.get_elapsed("last_pull").nil? || Timer.get_elapsed("last_pull") > 60*60*2) add "<%`git pull 2>&1`%>" add "<%Timer.set_timestamp('last_pull')%>" end end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
dev_tasks-1.0.38 | lib/pull.rb |
dev_tasks-1.0.37 | lib/pull.rb |