null+****@clear*****
null+****@clear*****
2011年 11月 30日 (水) 10:41:07 JST
Susumu Yata 2011-11-30 01:41:07 +0000 (Wed, 30 Nov 2011)
New Revision: fe6d03a08e76e130865daa8525593f430245823b
Log:
[doc] added DEFAULT_DB_NAME (tutorial.db) that is used when a database is unspecified.
Modified files:
doc/source/update_execution_example.py
Modified: doc/source/update_execution_example.py (+3 -0)
===================================================================
--- doc/source/update_execution_example.py 2011-11-30 01:36:51 +0000 (67406d4)
+++ doc/source/update_execution_example.py 2011-11-30 01:41:07 +0000 (0367eba)
@@ -9,6 +9,7 @@ import os.path
import shutil
DB_DIRECTORY = "/tmp/groonga-databases"
+DEFAULT_DB_NAME = "tutorial.db"
shutil.rmtree(DB_DIRECTORY, ignore_errors=True)
os.makedirs(DB_DIRECTORY)
@@ -35,6 +36,8 @@ def reconnect(name):
fout = None
def execmd(cmd, fout):
+ if not groonga_process:
+ reconnect(DEFAULT_DB_NAME)
a = '> ' + cmd + "\n"
stdout.write(a)
stdout.flush()