Sha256: bc1057aae8ea58e9e8c04c67b79d0044584df520a1d44f28bea05cead27ef7e5

Contents?: true

Size: 881 Bytes

Versions: 4

Compression:

Stored size: 881 Bytes

Contents

require 'fileutils'
namespace :mack do
  
  desc "Loads the Mack environment. Default is development."
  task :environment do
    require File.expand_path(File.join(File.dirname(__FILE__), '..', '..', 'mack'))
    Mack::Environment.load
  end # environment
  
  namespace :freeze do
    
    desc "Freezes the Edge Mack code into your vendor/framework folder"
    task :edge do
      f_dir = File.join(FileUtils.pwd, 'vendor', 'framework')
      FileUtils.mkdir_p(f_dir)
      %w{mack mack-more}.each do |proj|
        proj_dir = File.join(f_dir, proj)
        if File.exists?(proj_dir)
          FileUtils.cd proj_dir
          system 'git pull'
        else
          FileUtils.cd f_dir
          system "git clone git://github.com/#{ENV["USERNAME"] || 'markbates'}/#{proj}.git"
        end
      end
    end
    
  end
  
end # mack

alias_task :environment, "mack:environment"

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
mack-0.8.1 lib/mack/tasks/mack_tasks.rake
mack-0.8.2 lib/mack/tasks/mack_tasks.rake
mack-0.8.3 lib/mack/tasks/mack_tasks.rake
mack-0.8.3.1 lib/mack/tasks/mack_tasks.rake