Kexi/Handbook/References/Command-Line Options: Difference between revisions

From KDE UserBase Wiki
(→‎Options: The rest)
(→‎Options: Split to sections)
Line 10: Line 10:


===Options===
===Options===
;<tt>-h</tt>, <tt>--help</tt>
{{Note|If none of the below options are used, '''KEXI''' will open specified file (project).}}
:Displays help on commandline options.
 
;<tt>--help-all</tt>
====Options related to entire projects====
:Displays help including Qt specific options.
;<tt>-v</tt>, <tt>--version</tt>
:Displays version information.
;<tt>--author</tt>
:Show author information.
;<tt>--license</tt>
:Show license information.
;<tt>--desktopfile <file name></tt>
:The base file name of the desktop entry for this application.
;<tt>--createdb</tt>
;<tt>--createdb</tt>
:Create a new, blank project using specified database driver and database name and exit immediately. You will be asked for confirmation if overwriting is needed.
:Create a new, blank project using specified database driver and database name and exit immediately. You will be asked for confirmation if overwriting is needed.
Line 39: Line 30:
;<tt>--readonly</tt>
;<tt>--readonly</tt>
:Specify that any database connections will be performed without write support. This option is ignored when <tt>--createdb</tt> option is present, otherwise the database could not be created.
:Specify that any database connections will be performed without write support. This option is ignored when <tt>--createdb</tt> option is present, otherwise the database could not be created.
;<tt>--user-mode</tt>
 
:Start project in User Mode, regardless of the project settings.
====Options related to opening objects====
;<tt>--design-mode</tt>
:Start project in Design Mode, regardless of the project settings.
;<tt>--show-navigator</tt>
:Show the Project Navigator side pane even if '''KEXI''' runs in User Mode.
;<tt>--hide-menu</tt>
:Hide the main menu (the tabbed toolbar) completely. A number of commands from the main menu is still visible. This option is useful in User Mode.
;<tt>--open <[object_type:]object_name></tt>
;<tt>--open <[object_type:]object_name></tt>
:Open object of type <tt>'object_type'</tt> and name <tt>'object_name'</tt> from specified project on application start. <tt>'object_type'</tt> is optional, if omitted - table type is assumed. Other object types can be <tt>query</tt>, <tt>form</tt>, <tt>report</tt>, <tt>script</tt>. There may by more or less types available depending on '''KEXI''' plugins installed. Use <tt>""</tt> characters to specify names containing spaces. Examples: <tt>--open MyTable</tt>, <tt>--open query:"My very big query"</tt>
:Open object of type <tt>'object_type'</tt> and name <tt>'object_name'</tt> from specified project on application start. <tt>'object_type'</tt> is optional, if omitted - table type is assumed. Other object types can be <tt>query</tt>, <tt>form</tt>, <tt>report</tt>, <tt>script</tt>. There may by more or less types available depending on '''KEXI''' plugins installed. Use <tt>""</tt> characters to specify names containing spaces. Examples: <tt>--open MyTable</tt>, <tt>--open query:"My very big query"</tt>
Line 57: Line 42:
;<tt>--new <object_type></tt>
;<tt>--new <object_type></tt>
:Start design of a new object of type <tt>'object_type'</tt>.
:Start design of a new object of type <tt>'object_type'</tt>.
====Options related to database servers====
;<tt>-u</tt>, <tt>--user</tt>
;<tt>-u</tt>, <tt>--user</tt>
:Database server's user name when connecting to a project. Ignored if the project is opened using a shortcut file. Default user name is the same as the current login (user name).
:Database server's user name when connecting to a project. Ignored if the project is opened using a shortcut file. Default user name is the same as the current login (user name).
Line 67: Line 54:
;<tt>--skip-conn-dialog</tt>
;<tt>--skip-conn-dialog</tt>
:Skip displaying connection dialog window and connect directly. Available when opening <tt>.kexic</tt> or <tt>.kexis</tt> shortcut files.
:Skip displaying connection dialog window and connect directly. Available when opening <tt>.kexic</tt> or <tt>.kexis</tt> shortcut files.
====Options related to application mode or appearance====
;<tt>--user-mode</tt>
:Start project in User Mode, regardless of the project settings.
;<tt>--design-mode</tt>
:Start project in Design Mode, regardless of the project settings.
;<tt>--show-navigator</tt>
:Show the Project Navigator side pane even if '''KEXI''' runs in User Mode.
;<tt>--hide-menu</tt>
:Hide the main menu (the tabbed toolbar) completely. A number of commands from the main menu is still visible. This option is useful in User Mode.
;<tt>-f</tt>, <tt>--fullscreen</tt>
;<tt>-f</tt>, <tt>--fullscreen</tt>
:Start '''KEXI''' in full screen mode to occupy the whole screen area by hiding window decorations such as title bars.
:Start '''KEXI''' in full screen mode to occupy the whole screen area by hiding window decorations such as title bars.
====Obtaining help and other information====
;<tt>-h</tt>, <tt>--help</tt>
:Displays help on commandline options.
;<tt>--help-all</tt>
:Displays help including Qt specific options.
;<tt>-v</tt>, <tt>--version</tt>
:Displays version information.
;<tt>--author</tt>
:Show author information.
;<tt>--license</tt>
:Show license information.
;<tt>--list-plugins
;<tt>--list-plugins
:Display list of plugins available for '''KEXI''' with their  name, description, version and filenames.
:Display list of plugins available for '''KEXI''' with their  name, description, version and filenames.

Revision as of 21:11, 30 August 2023

Usage

The command-line interface provides the option to start the KEXI application, conveniently open projects within its environment, and carry out specific additional actions.

A general way to start the KEXI application:

kexi [options] file

Information

It is possible that the command kexi on your computer should be in the form of kexi-3.2 or kexi-3.3, depending on the version of the application installed. Such version-dependent naming of KEXI executable facilitate installation of multiple versions of KEXI.


Options

Note

If none of the below options are used, KEXI will open specified file (project).


Options related to entire projects

--createdb
Create a new, blank project using specified database driver and database name and exit immediately. You will be asked for confirmation if overwriting is needed.
--create-opendb
Like --createdb, but also open newly created database.
--dropdb
Drop (remove) a project using specified database driver and database name. You will be asked for confirmation.
--drv, --dbdriver <name_or_id>
Name of a database driver to be used when connecting to a database project ("sqlite" by default). Ignored if a shortcut filename is provided. Complete KDb-specific globally unique identifier can be used, e.g. "org.kde.kdb.sqlite" to specify exact vendor of the driver.
-t, --type <name>
Specify the type of file provided as an argument. This option is only useful if the filename does not have a valid extension set and its type cannot be determined unambiguously by examining its contents. This option is ignored if no file is specified as an argument. Available file types are:
  • "project" for a project file (the default)
  • "shortcut" for a shortcut file pointing to a project.
  • "connection" for database connection data.
--conn, --connection <shortcut_filename>
Specify a database connection shortcut .kexic file containing connection data. Can be used with --createdb or --create-opendb for convenience instead of using options such as --user, --host or --port. Note: Options like --user, --host have precedence over settings defined in the shortcut file.
--readonly
Specify that any database connections will be performed without write support. This option is ignored when --createdb option is present, otherwise the database could not be created.

Options related to opening objects

--open <[object_type:]object_name>
Open object of type 'object_type' and name 'object_name' from specified project on application start. 'object_type' is optional, if omitted - table type is assumed. Other object types can be query, form, report, script. There may by more or less types available depending on KEXI plugins installed. Use "" characters to specify names containing spaces. Examples: --open MyTable, --open query:"My very big query"
--design <[object_type:]object_name>
Like --open, but the object will be opened in Design Mode, if one is available.
--edittext <[object_type:]object_name>
Like --open, but the object will be opened in Text Mode, if one is available.
--execute, --exec <[object_type:]object_name>
Start execution of object of type 'object_type' and name 'object_name' on application start. 'object_type' is optional, if omitted - macro type is assumed. Object type can be also script. There may by more or less types available depending on KEXI plugins installed. Use "" characters to specify names containing spaces.
--new <object_type>
Start design of a new object of type 'object_type'.

Options related to database servers

-u, --user
Database server's user name when connecting to a project. Ignored if the project is opened using a shortcut file. Default user name is the same as the current login (user name).
--host <name>
Network server's (host) name to be used when connecting to a database project. Ignored if the project is opened using a shortcut file. Default host is the local computer.
--port <number>
Network server's port number to be used when connecting to a database project. Ignored if the project is opened using a shortcut file. Defaults depend on the used server type (e.g. MySQL, PostgreSQL).
--socket, --local-socket <filename>
Local computer's socket filename to be used when connecting to a database project. Ignored if the project is opened using a shortcut file. Defaults depend on the used server type (e.g. MySQL, PostgreSQL).
--skip-conn-dialog
Skip displaying connection dialog window and connect directly. Available when opening .kexic or .kexis shortcut files.

Options related to application mode or appearance

--user-mode
Start project in User Mode, regardless of the project settings.
--design-mode
Start project in Design Mode, regardless of the project settings.
--show-navigator
Show the Project Navigator side pane even if KEXI runs in User Mode.
--hide-menu
Hide the main menu (the tabbed toolbar) completely. A number of commands from the main menu is still visible. This option is useful in User Mode.
-f, --fullscreen
Start KEXI in full screen mode to occupy the whole screen area by hiding window decorations such as title bars.

Obtaining help and other information

-h, --help
Displays help on commandline options.
--help-all
Displays help including Qt specific options.
-v, --version
Displays version information.
--author
Show author information.
--license
Show license information.
--list-plugins
Display list of plugins available for KEXI with their name, description, version and filenames.