mirror of
https://github.com/h-sphere/sql-seal.git
synced 2026-07-22 10:10:28 +00:00
feat: updated created_at and modified_at from JS unix epoch to ISO 8601 for ease-of-use
This commit is contained in:
parent
2d1b3cbff4
commit
42e6b3bfd0
6 changed files with 15 additions and 7 deletions
|
|
@ -1,3 +1,10 @@
|
|||
# 0.22.0 (2025-01-31)
|
||||
Breaking change: `created_at` and `modified_at` has been changed from JS unix epoch to ISO 8601 dates (human readable). Thanks to that many of date operations are now easier to perform.
|
||||
Example, extracting year from the creation date:
|
||||
Before: `strftime("%Y", datetime(ROUND(created_at / 1000), 'unixepoch'))`
|
||||
Now: `strftime("%Y", created_at)`
|
||||
|
||||
|
||||
# 0.21.3 (2025-01-31)
|
||||
- fix: fixed issue with inline queries breaking rendering
|
||||
|
||||
|
|
|
|||
|
|
@ -18,8 +18,8 @@ Files table consists of the following columns:
|
|||
| `id` | File Path | |
|
||||
| `path` | Same as `id`, file path | |
|
||||
| `name` | Name of the file, without path and extension | |
|
||||
| `created_at` | Time of creation (unix timestamp). You can use it to order files by their creation date | 0.18.1 |
|
||||
| `modified_at` | Time of last modification (unix timestamp). You can use it to odrer files by their modification | 0.18.1 |
|
||||
| `created_at` | Time of creation (ISO 8601). You can use it to order files by their creation date. Before version 0.22.0 value was unixepoch * 1000 (JavaScript epoch) | 0.18.1 |
|
||||
| `modified_at` | Time of last modification (ISO 8601). You can use it to odrer files by their modification. Before version 0.22.0 value was unixepoch * 1000 (JavaScript epoch) | 0.18.1 |
|
||||
| `file_size` | Size of the file on disk (in bytes) | 0.18.1 |
|
||||
| All file properties | All file properties are also added to the table. All the special characters will be transformed to underscores `_`, so for example `note type` will be accessible as `note_type` | |
|
||||
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
{
|
||||
"id": "sqlseal",
|
||||
"name": "SQLSeal",
|
||||
"version": "0.21.3",
|
||||
"version": "0.22.0",
|
||||
"minAppVersion": "0.15.0",
|
||||
"description": "Use SQL in your notes to query your vault files and CSV content.",
|
||||
"author": "hypersphere",
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
{
|
||||
"name": "sqlseal",
|
||||
"version": "0.21.3",
|
||||
"version": "0.22.0",
|
||||
"description": "A plugin for Obsidian that allows you to run SQL queries on your notes.",
|
||||
"main": "main.js",
|
||||
"scripts": {
|
||||
|
|
|
|||
|
|
@ -23,8 +23,8 @@ function fileData(file: TFile, { tags: _tags, ...frontmatter }: Record<string, a
|
|||
id: file.path,
|
||||
path: file.path,
|
||||
name: file.name.replace(/\.[^/.]+$/, ""),
|
||||
created_at: file.stat.ctime,
|
||||
modified_at: file.stat.mtime,
|
||||
created_at: (new Date(file.stat.ctime)).toISOString(),
|
||||
modified_at: (new Date(file.stat.mtime)).toISOString(),
|
||||
file_size: file.stat.size
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -35,5 +35,6 @@
|
|||
"0.21.0": "0.15.0",
|
||||
"0.21.1": "0.15.0",
|
||||
"0.21.2": "0.15.0",
|
||||
"0.21.3": "0.15.0"
|
||||
"0.21.3": "0.15.0",
|
||||
"0.22.0": "0.15.0"
|
||||
}
|
||||
Loading…
Reference in a new issue