@telorun/sql 0.1.4 → 0.1.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md
CHANGED
|
@@ -28,8 +28,9 @@ class SqlMigrationsResource {
|
|
|
28
28
|
const migrations = [];
|
|
29
29
|
for (const [, { resource }] of this.ctx.moduleContext.resourceInstances) {
|
|
30
30
|
if (resource.kind === "Sql.Migration") {
|
|
31
|
+
const version = (resource.version ?? resource.metadata.name);
|
|
31
32
|
migrations.push({
|
|
32
|
-
name:
|
|
33
|
+
name: version,
|
|
33
34
|
sql: resource.sql,
|
|
34
35
|
});
|
|
35
36
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@telorun/sql",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.6",
|
|
4
4
|
"description": "Telo SQL module - SQL database resource kinds for Telo manifests.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"telo",
|
|
@@ -63,7 +63,7 @@
|
|
|
63
63
|
"better-sqlite3": "^12.8.0",
|
|
64
64
|
"pg": "^8.20.0",
|
|
65
65
|
"kysely": "^0.28.15",
|
|
66
|
-
"@telorun/sdk": "0.3.
|
|
66
|
+
"@telorun/sdk": "0.3.2"
|
|
67
67
|
},
|
|
68
68
|
"devDependencies": {
|
|
69
69
|
"@types/better-sqlite3": "^7.0.0",
|
|
@@ -49,8 +49,9 @@ class SqlMigrationsResource implements ResourceInstance {
|
|
|
49
49
|
const migrations: MigrationEntry[] = [];
|
|
50
50
|
for (const [, { resource }] of this.ctx.moduleContext.resourceInstances) {
|
|
51
51
|
if (resource.kind === "Sql.Migration") {
|
|
52
|
+
const version = (resource.version ?? resource.metadata.name) as string;
|
|
52
53
|
migrations.push({
|
|
53
|
-
name:
|
|
54
|
+
name: version,
|
|
54
55
|
sql: resource.sql as string,
|
|
55
56
|
});
|
|
56
57
|
}
|