powersync 0.1.0
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 +339 -0
- package/bin/dev.cmd +3 -0
- package/bin/dev.js +9 -0
- package/bin/run.cmd +3 -0
- package/bin/run.js +8 -0
- package/dist/commands/init.d.ts +7 -0
- package/dist/commands/init.js +49 -0
- package/dist/commands/instance/config.d.ts +6 -0
- package/dist/commands/instance/config.js +23 -0
- package/dist/commands/instance/create.d.ts +16 -0
- package/dist/commands/instance/create.js +163 -0
- package/dist/commands/instance/deploy.d.ts +15 -0
- package/dist/commands/instance/deploy.js +142 -0
- package/dist/commands/instance/destroy.d.ts +9 -0
- package/dist/commands/instance/destroy.js +42 -0
- package/dist/commands/instance/schema.d.ts +6 -0
- package/dist/commands/instance/schema.js +20 -0
- package/dist/commands/instance/set.d.ts +9 -0
- package/dist/commands/instance/set.js +31 -0
- package/dist/commands/instance/status.d.ts +6 -0
- package/dist/commands/instance/status.js +21 -0
- package/dist/commands/instance/stop.d.ts +9 -0
- package/dist/commands/instance/stop.js +42 -0
- package/dist/commands/instance/sync-rules/deploy.d.ts +10 -0
- package/dist/commands/instance/sync-rules/deploy.js +49 -0
- package/dist/commands/instance/sync-rules/generate-schema.d.ts +10 -0
- package/dist/commands/instance/sync-rules/generate-schema.js +55 -0
- package/dist/commands/instance/sync-rules/validate.d.ts +9 -0
- package/dist/commands/instance/sync-rules/validate.js +29 -0
- package/dist/commands/instances.d.ts +6 -0
- package/dist/commands/instances.js +20 -0
- package/dist/constants.d.ts +11 -0
- package/dist/constants.js +8 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.js +1 -0
- package/dist/powersync-sdk/accounts/api.d.ts +717 -0
- package/dist/powersync-sdk/accounts/api.js +182 -0
- package/dist/powersync-sdk/accounts/client.d.ts +1096 -0
- package/dist/powersync-sdk/accounts/client.js +124 -0
- package/dist/powersync-sdk/accounts/codecs.d.ts +32 -0
- package/dist/powersync-sdk/accounts/codecs.js +93 -0
- package/dist/powersync-sdk/accounts/index.d.ts +4 -0
- package/dist/powersync-sdk/accounts/index.js +4 -0
- package/dist/powersync-sdk/accounts/models.d.ts +260 -0
- package/dist/powersync-sdk/accounts/models.js +96 -0
- package/dist/powersync-sdk/accounts/routes.d.ts +44 -0
- package/dist/powersync-sdk/accounts/routes.js +45 -0
- package/dist/powersync-sdk/accounts/source.d.ts +76 -0
- package/dist/powersync-sdk/accounts/source.js +32 -0
- package/dist/powersync-sdk/errors/errors.d.ts +62 -0
- package/dist/powersync-sdk/errors/errors.js +115 -0
- package/dist/powersync-sdk/errors/index.d.ts +2 -0
- package/dist/powersync-sdk/errors/index.js +2 -0
- package/dist/powersync-sdk/errors/utils.d.ts +4 -0
- package/dist/powersync-sdk/errors/utils.js +18 -0
- package/dist/powersync-sdk/fetch-clients/codecs.d.ts +4 -0
- package/dist/powersync-sdk/fetch-clients/codecs.js +34 -0
- package/dist/powersync-sdk/fetch-clients/decoders.d.ts +3 -0
- package/dist/powersync-sdk/fetch-clients/decoders.js +35 -0
- package/dist/powersync-sdk/fetch-clients/definitions.d.ts +97 -0
- package/dist/powersync-sdk/fetch-clients/definitions.js +22 -0
- package/dist/powersync-sdk/fetch-clients/errors.d.ts +7 -0
- package/dist/powersync-sdk/fetch-clients/errors.js +19 -0
- package/dist/powersync-sdk/fetch-clients/index.d.ts +5 -0
- package/dist/powersync-sdk/fetch-clients/index.js +5 -0
- package/dist/powersync-sdk/fetch-clients/node-client.d.ts +9 -0
- package/dist/powersync-sdk/fetch-clients/node-client.js +107 -0
- package/dist/powersync-sdk/fetch-clients/request.d.ts +11 -0
- package/dist/powersync-sdk/fetch-clients/request.js +138 -0
- package/dist/powersync-sdk/fetch-clients/streaming.d.ts +65 -0
- package/dist/powersync-sdk/fetch-clients/streaming.js +99 -0
- package/dist/powersync-sdk/fetch-clients/utils.d.ts +13 -0
- package/dist/powersync-sdk/fetch-clients/utils.js +43 -0
- package/dist/powersync-sdk/fetch-clients/web-client.d.ts +14 -0
- package/dist/powersync-sdk/fetch-clients/web-client.js +56 -0
- package/dist/powersync-sdk/json/index.d.ts +4 -0
- package/dist/powersync-sdk/json/index.js +3 -0
- package/dist/powersync-sdk/json/json.d.ts +5 -0
- package/dist/powersync-sdk/json/json.js +35 -0
- package/dist/powersync-sdk/json/json_container.d.ts +18 -0
- package/dist/powersync-sdk/json/json_container.js +28 -0
- package/dist/powersync-sdk/json/json_stringify.d.ts +36 -0
- package/dist/powersync-sdk/json/json_stringify.js +162 -0
- package/dist/powersync-sdk/powersync/client.d.ts +449 -0
- package/dist/powersync-sdk/powersync/client.js +53 -0
- package/dist/powersync-sdk/powersync/config/HostedConfig.d.ts +327 -0
- package/dist/powersync-sdk/powersync/config/HostedConfig.js +92 -0
- package/dist/powersync-sdk/powersync/config/PowerSyncConfig.d.ts +211 -0
- package/dist/powersync-sdk/powersync/config/PowerSyncConfig.js +97 -0
- package/dist/powersync-sdk/powersync/config/normalize.d.ts +32 -0
- package/dist/powersync-sdk/powersync/config/normalize.js +85 -0
- package/dist/powersync-sdk/powersync/definitions.d.ts +149 -0
- package/dist/powersync-sdk/powersync/definitions.js +97 -0
- package/dist/powersync-sdk/powersync/index.d.ts +8 -0
- package/dist/powersync-sdk/powersync/index.js +8 -0
- package/dist/powersync-sdk/powersync/internal_routes.d.ts +247 -0
- package/dist/powersync-sdk/powersync/internal_routes.js +69 -0
- package/dist/powersync-sdk/powersync/routes.d.ts +779 -0
- package/dist/powersync-sdk/powersync/routes.js +191 -0
- package/dist/powersync-sdk/sdk-clients/endpoints.d.ts +31 -0
- package/dist/powersync-sdk/sdk-clients/endpoints.js +48 -0
- package/dist/powersync-sdk/sdk-clients/index.d.ts +3 -0
- package/dist/powersync-sdk/sdk-clients/index.js +3 -0
- package/dist/powersync-sdk/sdk-clients/pagination.d.ts +14 -0
- package/dist/powersync-sdk/sdk-clients/pagination.js +21 -0
- package/dist/powersync-sdk/sdk-clients/sdk-client.d.ts +17 -0
- package/dist/powersync-sdk/sdk-clients/sdk-client.js +30 -0
- package/dist/powersync-sdk/streaming/bson/buffer-array.d.ts +31 -0
- package/dist/powersync-sdk/streaming/bson/buffer-array.js +79 -0
- package/dist/powersync-sdk/streaming/bson/constants.d.ts +2 -0
- package/dist/powersync-sdk/streaming/bson/constants.js +1 -0
- package/dist/powersync-sdk/streaming/bson/decoder.d.ts +10 -0
- package/dist/powersync-sdk/streaming/bson/decoder.js +62 -0
- package/dist/powersync-sdk/streaming/bson/encoder.d.ts +10 -0
- package/dist/powersync-sdk/streaming/bson/encoder.js +23 -0
- package/dist/powersync-sdk/streaming/bson/header.d.ts +11 -0
- package/dist/powersync-sdk/streaming/bson/header.js +52 -0
- package/dist/powersync-sdk/streaming/bson/index.d.ts +5 -0
- package/dist/powersync-sdk/streaming/bson/index.js +5 -0
- package/dist/powersync-sdk/streaming/core/backpressure.d.ts +15 -0
- package/dist/powersync-sdk/streaming/core/backpressure.js +34 -0
- package/dist/powersync-sdk/streaming/core/cross-stream.d.ts +6 -0
- package/dist/powersync-sdk/streaming/core/cross-stream.js +17 -0
- package/dist/powersync-sdk/streaming/core/index.d.ts +4 -0
- package/dist/powersync-sdk/streaming/core/index.js +4 -0
- package/dist/powersync-sdk/streaming/core/node-utils.d.ts +7 -0
- package/dist/powersync-sdk/streaming/core/node-utils.js +11 -0
- package/dist/powersync-sdk/streaming/core/transformers.d.ts +41 -0
- package/dist/powersync-sdk/streaming/core/transformers.js +70 -0
- package/dist/powersync-sdk/streaming/core/utils.d.ts +36 -0
- package/dist/powersync-sdk/streaming/core/utils.js +66 -0
- package/dist/powersync-sdk/streaming/index.d.ts +3 -0
- package/dist/powersync-sdk/streaming/index.js +3 -0
- package/dist/powersync-sdk/streaming/web.d.ts +4 -0
- package/dist/powersync-sdk/streaming/web.js +4 -0
- package/dist/powersync-sdk/sync-rules/@syncpoint/wkx/binaryreader.d.ts +2 -0
- package/dist/powersync-sdk/sync-rules/@syncpoint/wkx/binaryreader.js +36 -0
- package/dist/powersync-sdk/sync-rules/@syncpoint/wkx/binarywriter.d.ts +2 -0
- package/dist/powersync-sdk/sync-rules/@syncpoint/wkx/binarywriter.js +58 -0
- package/dist/powersync-sdk/sync-rules/@syncpoint/wkx/geometry.d.ts +18 -0
- package/dist/powersync-sdk/sync-rules/@syncpoint/wkx/geometry.js +348 -0
- package/dist/powersync-sdk/sync-rules/@syncpoint/wkx/geometrycollection.d.ts +11 -0
- package/dist/powersync-sdk/sync-rules/@syncpoint/wkx/geometrycollection.js +118 -0
- package/dist/powersync-sdk/sync-rules/@syncpoint/wkx/linestring.d.ts +11 -0
- package/dist/powersync-sdk/sync-rules/@syncpoint/wkx/linestring.js +131 -0
- package/dist/powersync-sdk/sync-rules/@syncpoint/wkx/multilinestring.d.ts +11 -0
- package/dist/powersync-sdk/sync-rules/@syncpoint/wkx/multilinestring.js +134 -0
- package/dist/powersync-sdk/sync-rules/@syncpoint/wkx/multipoint.d.ts +11 -0
- package/dist/powersync-sdk/sync-rules/@syncpoint/wkx/multipoint.js +122 -0
- package/dist/powersync-sdk/sync-rules/@syncpoint/wkx/multipolygon.d.ts +11 -0
- package/dist/powersync-sdk/sync-rules/@syncpoint/wkx/multipolygon.js +158 -0
- package/dist/powersync-sdk/sync-rules/@syncpoint/wkx/point.d.ts +14 -0
- package/dist/powersync-sdk/sync-rules/@syncpoint/wkx/point.js +165 -0
- package/dist/powersync-sdk/sync-rules/@syncpoint/wkx/polygon.d.ts +11 -0
- package/dist/powersync-sdk/sync-rules/@syncpoint/wkx/polygon.js +207 -0
- package/dist/powersync-sdk/sync-rules/@syncpoint/wkx/types.d.ts +30 -0
- package/dist/powersync-sdk/sync-rules/@syncpoint/wkx/types.js +29 -0
- package/dist/powersync-sdk/sync-rules/@syncpoint/wkx/wktparser.d.ts +2 -0
- package/dist/powersync-sdk/sync-rules/@syncpoint/wkx/wktparser.js +111 -0
- package/dist/powersync-sdk/sync-rules/@syncpoint/wkx/wkx.d.ts +9 -0
- package/dist/powersync-sdk/sync-rules/@syncpoint/wkx/wkx.js +9 -0
- package/dist/powersync-sdk/sync-rules/@syncpoint/wkx/zigzag.d.ts +5 -0
- package/dist/powersync-sdk/sync-rules/@syncpoint/wkx/zigzag.js +9 -0
- package/dist/powersync-sdk/sync-rules/DartSchemaGenerator.d.ts +12 -0
- package/dist/powersync-sdk/sync-rules/DartSchemaGenerator.js +35 -0
- package/dist/powersync-sdk/sync-rules/ExpressionType.d.ts +33 -0
- package/dist/powersync-sdk/sync-rules/ExpressionType.js +62 -0
- package/dist/powersync-sdk/sync-rules/IdSequence.d.ts +4 -0
- package/dist/powersync-sdk/sync-rules/IdSequence.js +7 -0
- package/dist/powersync-sdk/sync-rules/JsSchemaGenerator.d.ts +12 -0
- package/dist/powersync-sdk/sync-rules/JsSchemaGenerator.js +38 -0
- package/dist/powersync-sdk/sync-rules/SchemaGenerator.d.ts +14 -0
- package/dist/powersync-sdk/sync-rules/SchemaGenerator.js +24 -0
- package/dist/powersync-sdk/sync-rules/SourceTableInterface.d.ts +5 -0
- package/dist/powersync-sdk/sync-rules/SourceTableInterface.js +1 -0
- package/dist/powersync-sdk/sync-rules/SqlBucketDescriptor.d.ts +37 -0
- package/dist/powersync-sdk/sync-rules/SqlBucketDescriptor.js +116 -0
- package/dist/powersync-sdk/sync-rules/SqlDataQuery.d.ts +39 -0
- package/dist/powersync-sdk/sync-rules/SqlDataQuery.js +245 -0
- package/dist/powersync-sdk/sync-rules/SqlParameterQuery.d.ts +43 -0
- package/dist/powersync-sdk/sync-rules/SqlParameterQuery.js +254 -0
- package/dist/powersync-sdk/sync-rules/SqlSyncRules.d.ts +52 -0
- package/dist/powersync-sdk/sync-rules/SqlSyncRules.js +252 -0
- package/dist/powersync-sdk/sync-rules/StaticSchema.d.ts +26 -0
- package/dist/powersync-sdk/sync-rules/StaticSchema.js +71 -0
- package/dist/powersync-sdk/sync-rules/StaticSqlParameterQuery.d.ts +24 -0
- package/dist/powersync-sdk/sync-rules/StaticSqlParameterQuery.js +71 -0
- package/dist/powersync-sdk/sync-rules/TablePattern.d.ts +17 -0
- package/dist/powersync-sdk/sync-rules/TablePattern.js +56 -0
- package/dist/powersync-sdk/sync-rules/TableQuerySchema.d.ts +9 -0
- package/dist/powersync-sdk/sync-rules/TableQuerySchema.js +41 -0
- package/dist/powersync-sdk/sync-rules/errors.d.ts +22 -0
- package/dist/powersync-sdk/sync-rules/errors.js +60 -0
- package/dist/powersync-sdk/sync-rules/generators.d.ts +6 -0
- package/dist/powersync-sdk/sync-rules/generators.js +6 -0
- package/dist/powersync-sdk/sync-rules/index.d.ts +17 -0
- package/dist/powersync-sdk/sync-rules/index.js +17 -0
- package/dist/powersync-sdk/sync-rules/json_schema.d.ts +3 -0
- package/dist/powersync-sdk/sync-rules/json_schema.js +50 -0
- package/dist/powersync-sdk/sync-rules/sql_filters.d.ts +91 -0
- package/dist/powersync-sdk/sync-rules/sql_filters.js +491 -0
- package/dist/powersync-sdk/sync-rules/sql_functions.d.ts +53 -0
- package/dist/powersync-sdk/sync-rules/sql_functions.js +755 -0
- package/dist/powersync-sdk/sync-rules/sql_support.d.ts +22 -0
- package/dist/powersync-sdk/sync-rules/sql_support.js +208 -0
- package/dist/powersync-sdk/sync-rules/types.d.ts +174 -0
- package/dist/powersync-sdk/sync-rules/types.js +9 -0
- package/dist/powersync-sdk/sync-rules/utils.d.ts +45 -0
- package/dist/powersync-sdk/sync-rules/utils.js +163 -0
- package/dist/service/accounts.client.d.ts +26 -0
- package/dist/service/accounts.client.js +26 -0
- package/dist/service/powersync.client.d.ts +269 -0
- package/dist/service/powersync.client.js +135 -0
- package/dist/service/types.d.ts +69 -0
- package/dist/service/types.js +1 -0
- package/dist/service/utils.d.ts +5 -0
- package/dist/service/utils.js +7 -0
- package/dist/utils.d.ts +6 -0
- package/dist/utils.js +52 -0
- package/oclif.manifest.json +514 -0
- package/package.json +81 -0
|
@@ -0,0 +1,514 @@
|
|
|
1
|
+
{
|
|
2
|
+
"commands": {
|
|
3
|
+
"init": {
|
|
4
|
+
"aliases": [],
|
|
5
|
+
"args": {},
|
|
6
|
+
"description": "Initialize the CLI",
|
|
7
|
+
"examples": [
|
|
8
|
+
"<%= config.bin %> <%= command.id %>"
|
|
9
|
+
],
|
|
10
|
+
"flags": {},
|
|
11
|
+
"hasDynamicHelp": false,
|
|
12
|
+
"hiddenAliases": [],
|
|
13
|
+
"id": "init",
|
|
14
|
+
"pluginAlias": "powersync",
|
|
15
|
+
"pluginName": "powersync",
|
|
16
|
+
"pluginType": "core",
|
|
17
|
+
"strict": true,
|
|
18
|
+
"enableJsonFlag": false,
|
|
19
|
+
"isESM": true,
|
|
20
|
+
"relativePath": [
|
|
21
|
+
"dist",
|
|
22
|
+
"commands",
|
|
23
|
+
"init.js"
|
|
24
|
+
]
|
|
25
|
+
},
|
|
26
|
+
"instances": {
|
|
27
|
+
"aliases": [],
|
|
28
|
+
"args": {},
|
|
29
|
+
"description": "view list of instances",
|
|
30
|
+
"examples": [
|
|
31
|
+
"<%= config.bin %> <%= command.id %>"
|
|
32
|
+
],
|
|
33
|
+
"flags": {},
|
|
34
|
+
"hasDynamicHelp": false,
|
|
35
|
+
"hiddenAliases": [],
|
|
36
|
+
"id": "instances",
|
|
37
|
+
"pluginAlias": "powersync",
|
|
38
|
+
"pluginName": "powersync",
|
|
39
|
+
"pluginType": "core",
|
|
40
|
+
"strict": true,
|
|
41
|
+
"enableJsonFlag": false,
|
|
42
|
+
"isESM": true,
|
|
43
|
+
"relativePath": [
|
|
44
|
+
"dist",
|
|
45
|
+
"commands",
|
|
46
|
+
"instances.js"
|
|
47
|
+
]
|
|
48
|
+
},
|
|
49
|
+
"instance:config": {
|
|
50
|
+
"aliases": [],
|
|
51
|
+
"args": {},
|
|
52
|
+
"description": "get the instance config",
|
|
53
|
+
"examples": [
|
|
54
|
+
"<%= config.bin %> <%= command.id %>"
|
|
55
|
+
],
|
|
56
|
+
"flags": {},
|
|
57
|
+
"hasDynamicHelp": false,
|
|
58
|
+
"hiddenAliases": [],
|
|
59
|
+
"id": "instance:config",
|
|
60
|
+
"pluginAlias": "powersync",
|
|
61
|
+
"pluginName": "powersync",
|
|
62
|
+
"pluginType": "core",
|
|
63
|
+
"strict": true,
|
|
64
|
+
"enableJsonFlag": false,
|
|
65
|
+
"isESM": true,
|
|
66
|
+
"relativePath": [
|
|
67
|
+
"dist",
|
|
68
|
+
"commands",
|
|
69
|
+
"instance",
|
|
70
|
+
"config.js"
|
|
71
|
+
]
|
|
72
|
+
},
|
|
73
|
+
"instance:create": {
|
|
74
|
+
"aliases": [],
|
|
75
|
+
"args": {},
|
|
76
|
+
"description": "create a new instance",
|
|
77
|
+
"examples": [
|
|
78
|
+
"<%= config.bin %> <%= command.id %>"
|
|
79
|
+
],
|
|
80
|
+
"flags": {
|
|
81
|
+
"databaseName": {
|
|
82
|
+
"description": "Name of the DB",
|
|
83
|
+
"name": "databaseName",
|
|
84
|
+
"hasDynamicHelp": false,
|
|
85
|
+
"multiple": false,
|
|
86
|
+
"type": "option"
|
|
87
|
+
},
|
|
88
|
+
"databasePassword": {
|
|
89
|
+
"description": "Password of the DB",
|
|
90
|
+
"hidden": true,
|
|
91
|
+
"name": "databasePassword",
|
|
92
|
+
"hasDynamicHelp": false,
|
|
93
|
+
"multiple": false,
|
|
94
|
+
"type": "option"
|
|
95
|
+
},
|
|
96
|
+
"databaseUsername": {
|
|
97
|
+
"description": "Username of the DB",
|
|
98
|
+
"hidden": true,
|
|
99
|
+
"name": "databaseUsername",
|
|
100
|
+
"hasDynamicHelp": false,
|
|
101
|
+
"multiple": false,
|
|
102
|
+
"type": "option"
|
|
103
|
+
},
|
|
104
|
+
"hostname": {
|
|
105
|
+
"description": "Hostname to connect to DB",
|
|
106
|
+
"name": "hostname",
|
|
107
|
+
"hasDynamicHelp": false,
|
|
108
|
+
"multiple": false,
|
|
109
|
+
"type": "option"
|
|
110
|
+
},
|
|
111
|
+
"name": {
|
|
112
|
+
"description": "Name of the instance",
|
|
113
|
+
"name": "name",
|
|
114
|
+
"hasDynamicHelp": false,
|
|
115
|
+
"multiple": false,
|
|
116
|
+
"type": "option"
|
|
117
|
+
},
|
|
118
|
+
"port": {
|
|
119
|
+
"description": "Port number to connect to DB",
|
|
120
|
+
"name": "port",
|
|
121
|
+
"hasDynamicHelp": false,
|
|
122
|
+
"multiple": false,
|
|
123
|
+
"type": "option"
|
|
124
|
+
},
|
|
125
|
+
"region": {
|
|
126
|
+
"description": "Region to deploy instance to",
|
|
127
|
+
"name": "region",
|
|
128
|
+
"hasDynamicHelp": false,
|
|
129
|
+
"multiple": false,
|
|
130
|
+
"options": [
|
|
131
|
+
"US",
|
|
132
|
+
"EU"
|
|
133
|
+
],
|
|
134
|
+
"type": "option"
|
|
135
|
+
},
|
|
136
|
+
"useSupabaseAuth": {
|
|
137
|
+
"description": "Use Supabase for auth",
|
|
138
|
+
"name": "useSupabaseAuth",
|
|
139
|
+
"allowNo": false,
|
|
140
|
+
"type": "boolean"
|
|
141
|
+
}
|
|
142
|
+
},
|
|
143
|
+
"hasDynamicHelp": false,
|
|
144
|
+
"hiddenAliases": [],
|
|
145
|
+
"id": "instance:create",
|
|
146
|
+
"pluginAlias": "powersync",
|
|
147
|
+
"pluginName": "powersync",
|
|
148
|
+
"pluginType": "core",
|
|
149
|
+
"strict": true,
|
|
150
|
+
"enableJsonFlag": false,
|
|
151
|
+
"isESM": true,
|
|
152
|
+
"relativePath": [
|
|
153
|
+
"dist",
|
|
154
|
+
"commands",
|
|
155
|
+
"instance",
|
|
156
|
+
"create.js"
|
|
157
|
+
]
|
|
158
|
+
},
|
|
159
|
+
"instance:deploy": {
|
|
160
|
+
"aliases": [],
|
|
161
|
+
"args": {},
|
|
162
|
+
"description": "deploy changes to an existing instance",
|
|
163
|
+
"examples": [
|
|
164
|
+
"<%= config.bin %> <%= command.id %>"
|
|
165
|
+
],
|
|
166
|
+
"flags": {
|
|
167
|
+
"databaseName": {
|
|
168
|
+
"description": "Name of the DB",
|
|
169
|
+
"name": "databaseName",
|
|
170
|
+
"hasDynamicHelp": false,
|
|
171
|
+
"multiple": false,
|
|
172
|
+
"type": "option"
|
|
173
|
+
},
|
|
174
|
+
"databasePassword": {
|
|
175
|
+
"description": "Password of the DB",
|
|
176
|
+
"hidden": true,
|
|
177
|
+
"name": "databasePassword",
|
|
178
|
+
"hasDynamicHelp": false,
|
|
179
|
+
"multiple": false,
|
|
180
|
+
"type": "option"
|
|
181
|
+
},
|
|
182
|
+
"databaseUsername": {
|
|
183
|
+
"description": "Username of the DB",
|
|
184
|
+
"hidden": true,
|
|
185
|
+
"name": "databaseUsername",
|
|
186
|
+
"hasDynamicHelp": false,
|
|
187
|
+
"multiple": false,
|
|
188
|
+
"type": "option"
|
|
189
|
+
},
|
|
190
|
+
"hostname": {
|
|
191
|
+
"description": "Hostname to connect to DB",
|
|
192
|
+
"name": "hostname",
|
|
193
|
+
"hasDynamicHelp": false,
|
|
194
|
+
"multiple": false,
|
|
195
|
+
"type": "option"
|
|
196
|
+
},
|
|
197
|
+
"name": {
|
|
198
|
+
"description": "Name of the instance",
|
|
199
|
+
"name": "name",
|
|
200
|
+
"hasDynamicHelp": false,
|
|
201
|
+
"multiple": false,
|
|
202
|
+
"type": "option"
|
|
203
|
+
},
|
|
204
|
+
"port": {
|
|
205
|
+
"description": "Port number to connect to DB",
|
|
206
|
+
"name": "port",
|
|
207
|
+
"hasDynamicHelp": false,
|
|
208
|
+
"multiple": false,
|
|
209
|
+
"type": "option"
|
|
210
|
+
},
|
|
211
|
+
"useSupabaseAuth": {
|
|
212
|
+
"description": "Use Supabase auth",
|
|
213
|
+
"name": "useSupabaseAuth",
|
|
214
|
+
"allowNo": false,
|
|
215
|
+
"type": "boolean"
|
|
216
|
+
}
|
|
217
|
+
},
|
|
218
|
+
"hasDynamicHelp": false,
|
|
219
|
+
"hiddenAliases": [],
|
|
220
|
+
"id": "instance:deploy",
|
|
221
|
+
"pluginAlias": "powersync",
|
|
222
|
+
"pluginName": "powersync",
|
|
223
|
+
"pluginType": "core",
|
|
224
|
+
"strict": true,
|
|
225
|
+
"enableJsonFlag": false,
|
|
226
|
+
"isESM": true,
|
|
227
|
+
"relativePath": [
|
|
228
|
+
"dist",
|
|
229
|
+
"commands",
|
|
230
|
+
"instance",
|
|
231
|
+
"deploy.js"
|
|
232
|
+
]
|
|
233
|
+
},
|
|
234
|
+
"instance:destroy": {
|
|
235
|
+
"aliases": [],
|
|
236
|
+
"args": {},
|
|
237
|
+
"description": "destroy the current instance - THIS CANNOT BE UNDONE",
|
|
238
|
+
"examples": [
|
|
239
|
+
"<%= config.bin %> <%= command.id %>",
|
|
240
|
+
"<%= config.bin %> <%= command.id %> --instanceId=1234"
|
|
241
|
+
],
|
|
242
|
+
"flags": {
|
|
243
|
+
"skipConfirmation": {
|
|
244
|
+
"char": "s",
|
|
245
|
+
"description": "Ignore confirmation question",
|
|
246
|
+
"name": "skipConfirmation",
|
|
247
|
+
"allowNo": false,
|
|
248
|
+
"type": "boolean"
|
|
249
|
+
}
|
|
250
|
+
},
|
|
251
|
+
"hasDynamicHelp": false,
|
|
252
|
+
"hiddenAliases": [],
|
|
253
|
+
"id": "instance:destroy",
|
|
254
|
+
"pluginAlias": "powersync",
|
|
255
|
+
"pluginName": "powersync",
|
|
256
|
+
"pluginType": "core",
|
|
257
|
+
"strict": true,
|
|
258
|
+
"enableJsonFlag": false,
|
|
259
|
+
"isESM": true,
|
|
260
|
+
"relativePath": [
|
|
261
|
+
"dist",
|
|
262
|
+
"commands",
|
|
263
|
+
"instance",
|
|
264
|
+
"destroy.js"
|
|
265
|
+
]
|
|
266
|
+
},
|
|
267
|
+
"instance:schema": {
|
|
268
|
+
"aliases": [],
|
|
269
|
+
"args": {},
|
|
270
|
+
"description": "view the schema of the current instance",
|
|
271
|
+
"examples": [
|
|
272
|
+
"<%= config.bin %> <%= command.id %>"
|
|
273
|
+
],
|
|
274
|
+
"flags": {},
|
|
275
|
+
"hasDynamicHelp": false,
|
|
276
|
+
"hiddenAliases": [],
|
|
277
|
+
"id": "instance:schema",
|
|
278
|
+
"pluginAlias": "powersync",
|
|
279
|
+
"pluginName": "powersync",
|
|
280
|
+
"pluginType": "core",
|
|
281
|
+
"strict": true,
|
|
282
|
+
"enableJsonFlag": false,
|
|
283
|
+
"isESM": true,
|
|
284
|
+
"relativePath": [
|
|
285
|
+
"dist",
|
|
286
|
+
"commands",
|
|
287
|
+
"instance",
|
|
288
|
+
"schema.js"
|
|
289
|
+
]
|
|
290
|
+
},
|
|
291
|
+
"instance:set": {
|
|
292
|
+
"aliases": [],
|
|
293
|
+
"args": {},
|
|
294
|
+
"description": "set the current instance",
|
|
295
|
+
"examples": [
|
|
296
|
+
"<%= config.bin %> <%= command.id %>",
|
|
297
|
+
"<%= config.bin %> <%= command.id %> --instanceId=1234"
|
|
298
|
+
],
|
|
299
|
+
"flags": {
|
|
300
|
+
"instanceId": {
|
|
301
|
+
"char": "n",
|
|
302
|
+
"description": "instance id to change to",
|
|
303
|
+
"name": "instanceId",
|
|
304
|
+
"hasDynamicHelp": false,
|
|
305
|
+
"multiple": false,
|
|
306
|
+
"type": "option"
|
|
307
|
+
}
|
|
308
|
+
},
|
|
309
|
+
"hasDynamicHelp": false,
|
|
310
|
+
"hiddenAliases": [],
|
|
311
|
+
"id": "instance:set",
|
|
312
|
+
"pluginAlias": "powersync",
|
|
313
|
+
"pluginName": "powersync",
|
|
314
|
+
"pluginType": "core",
|
|
315
|
+
"strict": true,
|
|
316
|
+
"enableJsonFlag": false,
|
|
317
|
+
"isESM": true,
|
|
318
|
+
"relativePath": [
|
|
319
|
+
"dist",
|
|
320
|
+
"commands",
|
|
321
|
+
"instance",
|
|
322
|
+
"set.js"
|
|
323
|
+
]
|
|
324
|
+
},
|
|
325
|
+
"instance:status": {
|
|
326
|
+
"aliases": [],
|
|
327
|
+
"args": {},
|
|
328
|
+
"description": "view the status of the current instance",
|
|
329
|
+
"examples": [
|
|
330
|
+
"<%= config.bin %> <%= command.id %>"
|
|
331
|
+
],
|
|
332
|
+
"flags": {},
|
|
333
|
+
"hasDynamicHelp": false,
|
|
334
|
+
"hiddenAliases": [],
|
|
335
|
+
"id": "instance:status",
|
|
336
|
+
"pluginAlias": "powersync",
|
|
337
|
+
"pluginName": "powersync",
|
|
338
|
+
"pluginType": "core",
|
|
339
|
+
"strict": true,
|
|
340
|
+
"enableJsonFlag": false,
|
|
341
|
+
"isESM": true,
|
|
342
|
+
"relativePath": [
|
|
343
|
+
"dist",
|
|
344
|
+
"commands",
|
|
345
|
+
"instance",
|
|
346
|
+
"status.js"
|
|
347
|
+
]
|
|
348
|
+
},
|
|
349
|
+
"instance:stop": {
|
|
350
|
+
"aliases": [],
|
|
351
|
+
"args": {},
|
|
352
|
+
"description": "stop the current instance",
|
|
353
|
+
"examples": [
|
|
354
|
+
"<%= config.bin %> <%= command.id %>",
|
|
355
|
+
"<%= config.bin %> <%= command.id %> --instanceId=1234"
|
|
356
|
+
],
|
|
357
|
+
"flags": {
|
|
358
|
+
"skipConfirmation": {
|
|
359
|
+
"char": "s",
|
|
360
|
+
"description": "Ignore confirmation question",
|
|
361
|
+
"name": "skipConfirmation",
|
|
362
|
+
"allowNo": false,
|
|
363
|
+
"type": "boolean"
|
|
364
|
+
}
|
|
365
|
+
},
|
|
366
|
+
"hasDynamicHelp": false,
|
|
367
|
+
"hiddenAliases": [],
|
|
368
|
+
"id": "instance:stop",
|
|
369
|
+
"pluginAlias": "powersync",
|
|
370
|
+
"pluginName": "powersync",
|
|
371
|
+
"pluginType": "core",
|
|
372
|
+
"strict": true,
|
|
373
|
+
"enableJsonFlag": false,
|
|
374
|
+
"isESM": true,
|
|
375
|
+
"relativePath": [
|
|
376
|
+
"dist",
|
|
377
|
+
"commands",
|
|
378
|
+
"instance",
|
|
379
|
+
"stop.js"
|
|
380
|
+
]
|
|
381
|
+
},
|
|
382
|
+
"instance:sync-rules:deploy": {
|
|
383
|
+
"aliases": [],
|
|
384
|
+
"args": {},
|
|
385
|
+
"description": "deploy sync rules from a local file to the current instance",
|
|
386
|
+
"examples": [
|
|
387
|
+
"<%= config.bin %> <%= command.id %>",
|
|
388
|
+
"<%= config.bin %> <%= command.id %> --filePath path/to/file",
|
|
389
|
+
"<%= config.bin %> <%= command.id %> -f path/to/file"
|
|
390
|
+
],
|
|
391
|
+
"flags": {
|
|
392
|
+
"filePath": {
|
|
393
|
+
"char": "f",
|
|
394
|
+
"description": "Path to the file",
|
|
395
|
+
"name": "filePath",
|
|
396
|
+
"required": true,
|
|
397
|
+
"hasDynamicHelp": false,
|
|
398
|
+
"multiple": false,
|
|
399
|
+
"type": "option"
|
|
400
|
+
},
|
|
401
|
+
"skipConfirmation": {
|
|
402
|
+
"char": "s",
|
|
403
|
+
"description": "Ignore confirmation question",
|
|
404
|
+
"name": "skipConfirmation",
|
|
405
|
+
"allowNo": false,
|
|
406
|
+
"type": "boolean"
|
|
407
|
+
}
|
|
408
|
+
},
|
|
409
|
+
"hasDynamicHelp": false,
|
|
410
|
+
"hiddenAliases": [],
|
|
411
|
+
"id": "instance:sync-rules:deploy",
|
|
412
|
+
"pluginAlias": "powersync",
|
|
413
|
+
"pluginName": "powersync",
|
|
414
|
+
"pluginType": "core",
|
|
415
|
+
"strict": true,
|
|
416
|
+
"enableJsonFlag": false,
|
|
417
|
+
"isESM": true,
|
|
418
|
+
"relativePath": [
|
|
419
|
+
"dist",
|
|
420
|
+
"commands",
|
|
421
|
+
"instance",
|
|
422
|
+
"sync-rules",
|
|
423
|
+
"deploy.js"
|
|
424
|
+
]
|
|
425
|
+
},
|
|
426
|
+
"instance:sync-rules:generate-schema": {
|
|
427
|
+
"aliases": [],
|
|
428
|
+
"args": {},
|
|
429
|
+
"description": "generate schema in your language from sync rules",
|
|
430
|
+
"examples": [
|
|
431
|
+
"<%= config.bin %> <%= command.id %>",
|
|
432
|
+
"<%= config.bin %> <%= command.id %> --filePath path/to/file",
|
|
433
|
+
"<%= config.bin %> <%= command.id %> -f path/to/file"
|
|
434
|
+
],
|
|
435
|
+
"flags": {
|
|
436
|
+
"filePath": {
|
|
437
|
+
"char": "f",
|
|
438
|
+
"description": "Path to the file",
|
|
439
|
+
"name": "filePath",
|
|
440
|
+
"required": true,
|
|
441
|
+
"hasDynamicHelp": false,
|
|
442
|
+
"multiple": false,
|
|
443
|
+
"type": "option"
|
|
444
|
+
},
|
|
445
|
+
"language": {
|
|
446
|
+
"char": "l",
|
|
447
|
+
"description": "Choose language for output",
|
|
448
|
+
"name": "language",
|
|
449
|
+
"hasDynamicHelp": false,
|
|
450
|
+
"multiple": false,
|
|
451
|
+
"options": [
|
|
452
|
+
"js",
|
|
453
|
+
"dart"
|
|
454
|
+
],
|
|
455
|
+
"type": "option"
|
|
456
|
+
}
|
|
457
|
+
},
|
|
458
|
+
"hasDynamicHelp": false,
|
|
459
|
+
"hiddenAliases": [],
|
|
460
|
+
"id": "instance:sync-rules:generate-schema",
|
|
461
|
+
"pluginAlias": "powersync",
|
|
462
|
+
"pluginName": "powersync",
|
|
463
|
+
"pluginType": "core",
|
|
464
|
+
"strict": true,
|
|
465
|
+
"enableJsonFlag": false,
|
|
466
|
+
"isESM": true,
|
|
467
|
+
"relativePath": [
|
|
468
|
+
"dist",
|
|
469
|
+
"commands",
|
|
470
|
+
"instance",
|
|
471
|
+
"sync-rules",
|
|
472
|
+
"generate-schema.js"
|
|
473
|
+
]
|
|
474
|
+
},
|
|
475
|
+
"instance:sync-rules:validate": {
|
|
476
|
+
"aliases": [],
|
|
477
|
+
"args": {},
|
|
478
|
+
"description": "validate sync rules from a local file",
|
|
479
|
+
"examples": [
|
|
480
|
+
"<%= config.bin %> <%= command.id %>",
|
|
481
|
+
"<%= config.bin %> <%= command.id %> --filePath path/to/file",
|
|
482
|
+
"<%= config.bin %> <%= command.id %> -f path/to/file"
|
|
483
|
+
],
|
|
484
|
+
"flags": {
|
|
485
|
+
"filePath": {
|
|
486
|
+
"char": "f",
|
|
487
|
+
"description": "Path to the file",
|
|
488
|
+
"name": "filePath",
|
|
489
|
+
"required": true,
|
|
490
|
+
"hasDynamicHelp": false,
|
|
491
|
+
"multiple": false,
|
|
492
|
+
"type": "option"
|
|
493
|
+
}
|
|
494
|
+
},
|
|
495
|
+
"hasDynamicHelp": false,
|
|
496
|
+
"hiddenAliases": [],
|
|
497
|
+
"id": "instance:sync-rules:validate",
|
|
498
|
+
"pluginAlias": "powersync",
|
|
499
|
+
"pluginName": "powersync",
|
|
500
|
+
"pluginType": "core",
|
|
501
|
+
"strict": true,
|
|
502
|
+
"enableJsonFlag": false,
|
|
503
|
+
"isESM": true,
|
|
504
|
+
"relativePath": [
|
|
505
|
+
"dist",
|
|
506
|
+
"commands",
|
|
507
|
+
"instance",
|
|
508
|
+
"sync-rules",
|
|
509
|
+
"validate.js"
|
|
510
|
+
]
|
|
511
|
+
}
|
|
512
|
+
},
|
|
513
|
+
"version": "0.1.0"
|
|
514
|
+
}
|
package/package.json
ADDED
|
@@ -0,0 +1,81 @@
|
|
|
1
|
+
{
|
|
2
|
+
"author": "JourneyApps",
|
|
3
|
+
"bin": {
|
|
4
|
+
"cli": "./bin/run.js"
|
|
5
|
+
},
|
|
6
|
+
"publishConfig": {
|
|
7
|
+
"registry": "https://registry.npmjs.org/",
|
|
8
|
+
"access": "public"
|
|
9
|
+
},
|
|
10
|
+
"description": "PowerSync CLI",
|
|
11
|
+
"engines": {
|
|
12
|
+
"node": ">=20.0.0"
|
|
13
|
+
},
|
|
14
|
+
"files": [
|
|
15
|
+
"/bin",
|
|
16
|
+
"/dist",
|
|
17
|
+
"/oclif.manifest.json"
|
|
18
|
+
],
|
|
19
|
+
"version": "0.1.0",
|
|
20
|
+
"bugs": "https://github.com/powersync-ja/cli/issues",
|
|
21
|
+
"types": "dist/index.d.ts",
|
|
22
|
+
"exports": "./lib/index.js",
|
|
23
|
+
"type": "module",
|
|
24
|
+
"homepage": "https://github.com/powersync-ja/cli",
|
|
25
|
+
"license": "UNLICENSED",
|
|
26
|
+
"name": "powersync",
|
|
27
|
+
"oclif": {
|
|
28
|
+
"bin": "powersync",
|
|
29
|
+
"dirname": "powersync",
|
|
30
|
+
"commands": "./dist/commands",
|
|
31
|
+
"plugins": [
|
|
32
|
+
"@oclif/plugin-help",
|
|
33
|
+
"@oclif/plugin-not-found"
|
|
34
|
+
],
|
|
35
|
+
"topicSeparator": " "
|
|
36
|
+
},
|
|
37
|
+
"repository": "powersync-ja/cli",
|
|
38
|
+
"dependencies": {
|
|
39
|
+
"@oclif/core": "^3.18.1",
|
|
40
|
+
"@oclif/plugin-help": "^6.0.11",
|
|
41
|
+
"@oclif/plugin-not-found": "^3.0.8",
|
|
42
|
+
"agentkeepalive": "^4.5.0",
|
|
43
|
+
"ajv": "^8.12.0",
|
|
44
|
+
"bson": "^4.7.2",
|
|
45
|
+
"dotenv": "^16.3.2",
|
|
46
|
+
"inquirer": "^9.2.12",
|
|
47
|
+
"lossless-json": "^4.0.1",
|
|
48
|
+
"ora": "^8.0.1",
|
|
49
|
+
"pgsql-ast-parser": "^12.0.1",
|
|
50
|
+
"ts-codec": "^1.2.2",
|
|
51
|
+
"uri-js": "^4.4.1",
|
|
52
|
+
"yaml": "^2.3.4"
|
|
53
|
+
},
|
|
54
|
+
"devDependencies": {
|
|
55
|
+
"@changesets/cli": "^2.27.1",
|
|
56
|
+
"@types/inquirer": "^9.0.7",
|
|
57
|
+
"@types/node": "^20.11.0",
|
|
58
|
+
"eslint": "^8.56.0",
|
|
59
|
+
"eslint-config-oclif": "^5",
|
|
60
|
+
"eslint-config-oclif-typescript": "^3.0.39",
|
|
61
|
+
"eslint-config-prettier": "^9.1.0",
|
|
62
|
+
"eslint-plugin-prettier": "^5.1.3",
|
|
63
|
+
"oclif": "^4.3.9",
|
|
64
|
+
"prettier": "^3.2.4",
|
|
65
|
+
"shx": "^0.3.4",
|
|
66
|
+
"strip-ansi": "^7.1.0",
|
|
67
|
+
"ts-node": "^10.9.2",
|
|
68
|
+
"typescript": "^5.3.3",
|
|
69
|
+
"vitest": "^1.2.1"
|
|
70
|
+
},
|
|
71
|
+
"scripts": {
|
|
72
|
+
"build": "shx rm -rf dist && tsc -b",
|
|
73
|
+
"lint": "eslint . --ext .ts",
|
|
74
|
+
"posttest": "npm run lint",
|
|
75
|
+
"test": "vitest",
|
|
76
|
+
"release": "pnpm build && pnpm changeset publish",
|
|
77
|
+
"prettier": "prettier --write .",
|
|
78
|
+
"version": "oclif readme && git add README.md",
|
|
79
|
+
"pack:tarballs": "oclif pack tarballs --parallel"
|
|
80
|
+
}
|
|
81
|
+
}
|