Ruby on Rails | Screencasts | Download | Documentation | Weblog | Community | Source

Changeset 2700

Show
Ignore:
Timestamp:
10/21/05 16:29:06 (3 years ago)
Author:
xal
Message:

Added ignore flags on data/* db/*.sqlite and log/*.

Changed checkout behavior so that there is no new full checkout made if a older checkout is already available. This takes load of textdrive when svn:exernals are used on the rails trunk.

Fixed a bug that prevented cia from running when there is a space in the project name

added new RAKE_TASK constant, its empty by default which means that the rake default task is run. This can be overridden by RAKE_TASK environment variable from the post_commit hook.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • tools/cia/trunk/app/models/build.rb

    r1143 r2700  
    1717  def checkout 
    1818    log "Checking out: #{directory}" 
    19     project.checkout(directory) 
     19    project.get(directory)      
    2020  end 
    2121   
    2222  def make 
    2323    log "Making..." 
    24     [ `cd #{directory} && #{RAKE_PATH}`, ($?.exitstatus == 0) ] 
     24    [ `cd #{directory} && #{RAKE_PATH} #{RAKE_TASK}`, ($?.exitstatus == 0) ] 
    2525  end 
    2626 
     
    3131   
    3232    def directory 
    33       RAILS_ROOT + "/data/#{project.name}/#{id}
     33      "\"#{RAILS_ROOT}/data/#{project.name}/current\"
    3434    end 
    3535 
  • tools/cia/trunk/app/models/project.rb

    r1114 r2700  
    66  end 
    77 
    8   def checkout(directory) 
    9     `svn checkout file://#{repository + "/" + path} #{directory}` 
     8  def get(directory) 
     9    if File.exists?(directory + '/.svn') 
     10      `svn update #{directory}` 
     11    else 
     12      `svn checkout file://#{repository + "/" + path} #{directory}` 
     13    end 
    1014  end 
    1115end 
  • tools/cia/trunk/config/environment.rb

    r1143 r2700  
    7272# Include your app's configuration here: 
    7373 
    74 RAKE_PATH             = '/usr/local/bin/rake' 
    75 SVN_LOOK_PATH         = '/usr/local/bin/svnlook' 
    76 NOTIFIER_FROM_ADDRESS = 'CIA <cia@rubyonrails.com>' 
     74RAKE_PATH             = '/usr/bin/rake' 
     75SVN_LOOK_PATH         = '/usr/bin/svnlook' 
     76NOTIFIER_FROM_ADDRESS = 'CIA <cia@jadedpixel.com>' 
     77 
     78# if you want to run a specific rake task for this application application 
     79# pass RAILS_ENV=task_name to the runner  
     80 
     81RAKE_TASK             = ENV['RAKE_TASK'] || '' 
  • tools/cia/trunk/data

    • Property svn:ignore set to
      *
  • tools/cia/trunk/db

    • Property svn:ignore set to
      *.sqlite
  • tools/cia/trunk/log

    • Property svn:ignore set to
      *