mirror of
https://github.com/zhigang1992/RubyMotion.git
synced 2026-01-12 22:51:55 +08:00
To replace your locally installed RubyMotion/lib folder with a checkout of this repository, use the task "rake install". To revert to the official release, use "rake uninstall"
22 lines
691 B
Ruby
22 lines
691 B
Ruby
installation_path = "/Library/RubyMotion"
|
|
|
|
desc "Replace your local installation with this checkout"
|
|
task :install do
|
|
if File.exist?("#{installation_path}/lib.backup")
|
|
raise "It seems this local checkout is already installed"
|
|
else
|
|
mv "#{installation_path}/lib", "#{installation_path}/lib.backup"
|
|
ln File.dirname(__FILE__) + "/lib", "#{installation_path}/lib"
|
|
end
|
|
end
|
|
|
|
desc "Go back to your original installation"
|
|
task :uninstall do
|
|
if !File.exist?("#{installation_path}/lib.backup")
|
|
raise "It seems this local checkout is not installed right now"
|
|
else
|
|
rm "#{installation_path}/lib"
|
|
mv "#{installation_path}/lib.backup", "#{installation_path}/lib"
|
|
end
|
|
end
|