]> scripts.mit.edu Git - wizard.git/blobdiff - wizard/sql.py
Rewrite parametrize to use new parametrizeWithVars
[wizard.git] / wizard / sql.py
index 6e8754a1cb7c1e43a310add61499933e93017831..5780dccd6bcb3e0c53bfce912dbde9f8773c3297 100644 (file)
@@ -1,4 +1,7 @@
 import sqlalchemy
+import os
+
+from wizard import shell
 
 # We're going to use sqlalchemy.engine.url.URL as our database
 # info intermediate object
@@ -28,7 +31,7 @@ def fill_url(url):
     # this is hook stuff
     if url.driver == "mysql":
         try:
-            url.host, url.username, url.password = sh.eval("/mit/scripts/sql/bin/get-password").split()
+            url.host, url.username, url.password = shell.Shell().eval("/mit/scripts/sql/bin/get-password").split()
             return url
         except shell.CallError:
             pass