 
 
 (defonce *current-app-id* (atom nil))
+(defonce *current-app-version* (atom nil))
+
+(defonce *current-server-port* (atom nil))
 
 
 (defn make-thread-environment-proxy [& {:keys [user-email user-admin?]}]

        application-id (if (.exists appengine-web-file)
                           (first (xpath-value appengine-web-file "//application"))
                           "appengine-magic-app")
        proxy-factory (ApiProxyLocalFactory.)
        environment (proxy [LocalServerEnvironment] []
                      (getAppDir [] dir)

                      (waitForServerToStart [] nil))
        api-proxy (.create proxy-factory environment)]
    (reset! *current-app-id* application-id)
    (reset! *current-app-version* application-version)
    (reset! *current-server-port* port)
    (ApiProxy/setDelegate api-proxy)
    ;; This installs a thread environment onto the REPL thread and allows App
    ;; Engine API calls to work in the REPL.
