The database 'new' sub-command
- The new command is a sub-command of the hkeydb command.
- It creates a new database file within the current directory, and is the first step in setting up a new database for a project.
-
new
- Creates a new Hyperkey database file in the current directory, named "_hkey.db.txt", and makes it the Hyperkey 'current database'.
- If the hkeydb command was invoked from the right-click menu in Windows, the 'current directory' will be set from the file or folder that was clicked upon.
-
EXAMPLES:
-
Create a new database in the current folder, and be prompted for
the project name:
-
cd C:\Users\Myuser\Documents\Project1
C:\Users\Myuser\Documents\Project1> hkeydb
COMMAND? new
CREATE DATABASE FILE "C:\Users\Myuser\Documents\Project1\_hkey.db.txt"? [N] y
--------------------------------------------
CREATING NEW DATABASE IN:
"C:\Users\Myuser\Documents\Project1\_hkey.db.txt"
--------------------------------------------
TITLE FOR DATABASE FILE? [Optional] Project1
USING DATABASE IN "C:\Users\Myuser\Documents\Project1\_hkey.db.txt" AS DEFAULT
--------------------------------------------
NEXT STEP: SET DEFAULT SERVER PATHS USING 'INIT' COMMAND
1. EXIT HYPERKEY PROGRAM
2. START WINDOWS EXPLORER
3. NAVIGATE TO SERVER FOLDER LOCATION USING WINDOWS EXPLORER
4. THEN RIGHT-CLICK ON A FILE IN THE FOLDER, OR THE FOLDER'S ICON'
TO RESTART 'HYPERKEY'
5. THEN SELECT 'INIT' OPTION
--------------------------------------------
COMMAND? x
- An empty database file is now created in the given folder.
- If the database will be used to do backups, then the server location must be defined within the database.
- As the banner text suggests, the user must exit the hkeydb command, then directly navigate to the server location that pairs with the local location, and then re-invoke the hkeydb command again and use the init sub-command.
-
-
Create a new database in folder 'c:\Users\Myuser\Documents' for project
"project2":
-
cd C:\Users\Myuser\Documents\Project2
C:\Users\Myuser\Documents\Project2> hkeydb -new -project "project2"
- This executes the new sub-command directly, without waiting for a prompt. The messages and prompts will be the same as for the first example above.
-
-
Create a new database in the current folder, and be prompted for
the project name: