Skip to content
Browse files

Can take a path argument

  • Loading branch information...
1 parent 7176962 commit 0beff1c1395c088168bd78987b33b545abefad94 @tinwelint tinwelint committed Aug 20, 2012
Showing with 5 additions and 2 deletions.
  1. +5 −2 shell/src/test/java/org/neo4j/shell/StartDbWithShell.java
View
7 shell/src/test/java/org/neo4j/shell/StartDbWithShell.java
@@ -22,16 +22,19 @@
import org.neo4j.graphdb.GraphDatabaseService;
import org.neo4j.graphdb.factory.GraphDatabaseFactory;
import org.neo4j.graphdb.factory.GraphDatabaseSetting;
+import org.neo4j.graphdb.factory.GraphDatabaseSettings;
public class StartDbWithShell
{
public static void main( String[] args ) throws Exception
{
+ String path = args.length > 0 ? args[0] : "target/test-data/shell-db";
GraphDatabaseService db = new GraphDatabaseFactory().
- newEmbeddedDatabaseBuilder( "target/test-data/shell-db" ).
+ newEmbeddedDatabaseBuilder( path ).
setConfig( ShellSettings.remote_shell_enabled, GraphDatabaseSetting.TRUE).
+ setConfig( GraphDatabaseSettings.allow_store_upgrade, GraphDatabaseSetting.TRUE).
newGraphDatabase();
- System.out.println( "ENTER to quit" );
+ System.out.println( "db " + path + " started, ENTER to quit" );
System.in.read();
db.shutdown();
}

0 comments on commit 0beff1c

Please sign in to comment.
Something went wrong with that request. Please try again.