Skip to content

Commit 931a759

Browse files
committed
sync docs
[skip ci]
1 parent 8a9998a commit 931a759

File tree

3 files changed

+11
-5
lines changed

3 files changed

+11
-5
lines changed

docs/building/migrations.mdx

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ All these three console applications the `tom` example, `tom` migrations for uni
6969

7070
## Prerequisites
7171

72-
Working MySQL database server as the `tom` migrations currently provides support only for the MySQL database.
72+
Any of the [supported databases](database/getting-started.mdx#introduction), `tom` is able to generate <a href='https://en.wikipedia.org/wiki/Data_definition_language' title='Data Definition Language'>DDL</a> queries for all these databases.
7373

7474
Install required dependencies and build the `TinyORM` library with the `tom` (it's enabled by default) as is described [here](building/hello-world.mdx#install-dependencies) and [here](building/tinyorm.mdx).
7575

@@ -191,6 +191,8 @@ And paste the following code.
191191
{charset_, qEnvironmentVariable("DB_MYSQL_CHARSET", UTF8MB4)},
192192
{collation_, qEnvironmentVariable("DB_MYSQL_COLLATION", UTF8MB40900aici)},
193193
{timezone_, TZ00},
194+
// Specifies what time zone all QDateTime-s will have
195+
{"qt_timezone", QVariant::fromValue(Qt::UTC)},
194196
{prefix_, EMPTY},
195197
{prefix_indexes, false},
196198
{strict_, true},
@@ -199,11 +201,11 @@ And paste the following code.
199201
{Version, {}}, // Autodetect
200202
{options_, QVariantHash()},
201203
},
202-
QStringLiteral("tinyorm_tom"));
204+
QStringLiteral("tinyorm_tom")); // shell:connection
203205
}
204206

205207
:::tip
206-
If you have defined more database connections then you can tag the lines with the database connection names with the `// shell:connection` comment and this connection names will be provided to the bash/zsh/pwsh completion for the `--database=` option, [example](https://github.com/silverqx/TinyORM/blob/main/examples/tom/main.cpp#L74).
208+
If you have defined more database connections then you can tag the lines with the database connection names with the `// shell:connection` comment and this connection names will be provided to the bash, zsh, pwsh completions for the `--database=` option 😎, [example](https://github.com/silverqx/TinyORM/blob/main/examples/tom/main.cpp#L74).
207209
:::
208210

209211
### Migrations

docs/building/tinyorm.mdx

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -542,6 +542,10 @@ On `Linux`, you can install the `range-v3` library and some other [dependencies]
542542
I recommend creating a new [`Session`](https://doc.qt.io/qtcreator/creator-project-managing-sessions.html) in the `QtCreator`, this way you will have all the examples in one place and as a bonus, everything will be in the same place when you close and reopen `QtCreator IDE`. You can name it `tinyorm.org` or `TinyORM examples`, it is up to you.
543543
:::
544544

545+
:::tip
546+
If you are using sessions, you can use a single `clangd` instance for all projects in this session in the `QtCreator IDE`. One significant advantage of this method is that the `.qtc_clangd/` folder will not be created in the build folder, but will be stored globally in the Roaming profile. You can enable it in the `Settings` - `C++` - `Clangd` - `Sessions with a single clangd instance`.
547+
:::
548+
545549
#### Configure TinyORM
546550

547551
Now you are ready to configure the `TinyORM` library. The `qmake` does not support auto-configuration of dependencies out of the box, to configure TinyORM's `qmake` build dependencies you have to copy the `conf.pri.example` file to the `conf.pri` and manually edit the `INCLUDEPATH` and `LIBS`. This way you can override any `qmake` build options or variables.

docs/database/getting-started.mdx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
sidebar_position: 0
33
sidebar_label: Getting Started
4-
description: TinyORM makes interacting with a database extremely simple using raw SQL, a fluent query builder, and the TinyORM. It provides first-party support for three databases MySQL/MariaDB, PostgreSQL, and SQLite.
4+
description: TinyORM makes interacting with a database extremely simple using raw SQL, a fluent query builder, and the TinyORM. It provides first-party support for four databases MySQL/MariaDB, PostgreSQL, and SQLite.
55
keywords: [c++ orm, database, getting started, tinyorm]
66
---
77

@@ -30,7 +30,7 @@ import {
3030

3131
## Introduction
3232

33-
Almost every modern application interacts with a database. TinyORM makes interacting with a database extremely simple using raw SQL, a [fluent query builder](database/query-builder.mdx), and the [TinyORM](tinyorm/getting-started.mdx). Currently, TinyORM provides first-party support for three databases:
33+
Almost every modern application interacts with a database. TinyORM makes interacting with a database extremely simple using raw SQL, a [fluent query builder](database/query-builder.mdx), and the [TinyORM](tinyorm/getting-started.mdx). Currently, TinyORM provides first-party support for four databases:
3434

3535
<div id='databases-supported-versions'>
3636

0 commit comments

Comments
 (0)