Sha256: e8adbf06dff21056ae7fb19a117b91606815014249a1850f4f825c47a68df21f
Contents?: true
Size: 1.6 KB
Versions: 3
Compression:
Stored size: 1.6 KB
Contents
require 'find' require 'fileutils' include FileUtils chdir File.dirname(__FILE__) $homedir = `echo ~`.to_s.strip $simdir = "#{$homedir}/Library/Application Support/iPhone Simulator/" $simapp="#{$homedir}/Library/Application Support/iPhone Simulator/User/Applications" $simlink="#{$homedir}/Library/Application Support/iPhone Simulator/User/Library/Preferences" $sim="/Developer/Platforms/iPhoneSimulator.platform/Developer/Applications" $guid="364FFCAF-C71D-4543-B293-9058E31CFFEE" $applog = File.join($homedir,"rholog.txt") `killall "iPhone Simulator"` Find.find($simdir) do |path| if File.basename(path) == "rhorunner.app" $guid = File.basename(File.dirname(path)) end end Dir.glob($simdir + '*').each do |sdk| simapp = sdk + "/Applications" simlink = sdk + "/Library/Preferences" simrhodes = File.join(simapp,$guid) rm_rf simrhodes mkdir_p File.join(simrhodes,"Documents") mkdir_p File.join(simrhodes,"Library","Preferences") puts `cp -R -p "rhorunner.app" "#{simrhodes}"` puts `ln -f -s "#{simlink}/com.apple.PeoplePicker.plist" "#{simrhodes}/Library/Preferences/com.apple.PeoplePicker.plist"` puts `ln -f -s "#{simlink}/.GlobalPreferences.plist" "#{simrhodes}/Library/Preferences/.GlobalPreferences.plist"` puts `echo "#{$applog}" > "#{simrhodes}/Documents/rhologpath.txt"` f = File.new("#{simapp}/#{$guid}.sb","w") f << "(version 1)\n(debug deny)\n(allow default)\n" f.close end system("open \"#{$sim}/iPhone Simulator.app\"")
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
rhodes-1.5.5 | platform/osx/Rhodes Launcher/launch.rb |
rhodes-1.5.4 | platform/osx/Rhodes Launcher/launch.rb |
rhodes-1.5.3 | platform/osx/Rhodes Launcher/launch.rb |