]> git.saurik.com Git - cycript.git/commitdiff
Added a global with around script file execution, so as to not break the world (yet).
authorJay Freeman (saurik) <saurik@saurik.com>
Sat, 7 Nov 2009 22:50:03 +0000 (22:50 +0000)
committerJay Freeman (saurik) <saurik@saurik.com>
Sat, 7 Nov 2009 22:50:03 +0000 (22:50 +0000)
Console.cpp

index 719e6f0fb24c8bc01ebeddec85cde0c848bdaf4c..fc745407a591bbc51d883736b51e2bfecbc6d06a 100644 (file)
@@ -608,8 +608,10 @@ int Main(int argc, char const * const argv[], char const * const envp[]) {
                 std::string code(str.str());
                 if (compile)
                     std::cout << code;
-                else
+                else {
+                    code = "with(Cycript.all){" + code + "}";
                     Run(client, code, stdout);
+                }
             }
     }