## Command Line Arguments

Invoking Password Safe with no arguments will cause the application to prompt you for the combination of the last database that was opened, or for the combination of a new database if none was previously opened on your machine (e.g., the first time you use Password Safe). It is, however, possible to modify this by invoking Password Safe as follows:

- pwsafe database
  This will open the specified database file, instead of the last one opened. If just a filename is given, without a path, it will be searched for in the directory in which the application was invoked. Note that if the filename an/or path has spaces, it should be enclosed in double quotes.
- pwsafe -r database
  This will open the database in read-only mode.
- pwsafe -v database
  This will validate the database after the correct passphrase is entered, correcting internal inconsistencies as necessary. Mostly useful when working with databases written by other applications.
- pwsafe -e filename
  This will prompt the user for a passphrase, and encrypt the file with a key derived from the passphrase. Note: The file can be any file. The encrypted file will have the same name as the original file, with ".PSF" appended to it.
- pwsafe -d filename
  This will prompt the user for a passphrase, and decrypt the file with a key derived from the passphrase. Note: This will work only on files that were encrypted by invoking pwsafe with the '-e' option (see above).
- pwsafe -c
  This will start the application closed, that is, with no database, and without the initial opening dialog (To access a database, use the File menu).
- pwsafe -s
  This will start the application "silently", that is, minimized and with no database. When the application is unminimized, the user is presented with the opening dialog box (This option is meant for starting the application upon login, via a shortcut in the user's Startup folder). Note: This implicitly puts the application in the system tray.
- pwsafe -m
  This is the same as the '-c' option, with the addition that the application is started as minimized.

In addition, the following options are accepted:

- -u username
  This will cause the application to read and write preferences under the specified username, instead of under the login name.
- -h hostname
  This will cause the application to read and write preferences under the specified hostname, instead of under the machine's name.
- -g config_file
  This will cause the specified file to be used for loading and storing preferences, instead of the default pwsafe.cfg. If just a filename is given, without a path, it will be searched for in the directory in which the application was invoked. Note that if the filename an/or path has spaces, it should be enclosed in double quotes.

These may be useful if you wish to share the same preferences across several machines, for example, when running Password Safe from a disk-on-key.