@rimori/client 2.5.49 → 2.5.50

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
@@ -98,10 +98,10 @@ Usage:
98
98
 
99
99
  ```bash
100
100
  pnpm build
101
- npx @rimori/client rimori-release alpha
101
+ npx @rimori/client rimori-release stable
102
102
  ```
103
103
 
104
- During initialization, convenience scripts (`release:alpha`, `release:stable`) are added to your project automatically.
104
+ During initialization, a convenience script (`release:stable`) is added to your project automatically.
105
105
 
106
106
  ## Runtime API
107
107
 
@@ -67,7 +67,6 @@ export function updatePackageJson({ pluginId, port, isUpgrade = false }) {
67
67
  dev: `vite --port ${port || 3000}`,
68
68
  build: 'pnpm check && vite build',
69
69
  check: 'tsc --project tsconfig.app.json --noEmit --pretty',
70
- 'release:alpha': 'pnpm build && pnpm rimori-release alpha',
71
70
  'release:stable': 'pnpm build && pnpm rimori-release stable',
72
71
  'dev:worker': 'VITE_MINIFY=false vite build --watch --config worker/vite.config.ts',
73
72
  'build:worker': 'vite build --config worker/vite.config.ts',
@@ -46,6 +46,10 @@ export default async function dbUpdate(config) {
46
46
  throw new Error('Database configuration object is empty or undefined');
47
47
  }
48
48
  console.log(`🗄️ Sending database configuration...`);
49
+ // release_channel is ignored by the backend (channels are retired, everything migrates into
50
+ // the `plugins` schema) but is still sent deliberately: a backend that has not picked up the
51
+ // change yet still validates it as required, and the CLI runs against an already-deployed
52
+ // backend, so dropping it here would break plugin sync during the deploy window.
49
53
  const requestBody = {
50
54
  db_config: dbConfigObject,
51
55
  release_channel: config.release_channel,
@@ -1,7 +1,7 @@
1
1
  #!/usr/bin/env node
2
2
  /**
3
3
  * Usage:
4
- * rimori-release <release_channel>
4
+ * rimori-release stable
5
5
  *
6
6
  * Environment variables required:
7
7
  * RIMORI_TOKEN - Your Rimori token
@@ -1,7 +1,7 @@
1
1
  #!/usr/bin/env node
2
2
  /**
3
3
  * Usage:
4
- * rimori-release <release_channel>
4
+ * rimori-release stable
5
5
  *
6
6
  * Environment variables required:
7
7
  * RIMORI_TOKEN - Your Rimori token
@@ -32,11 +32,15 @@ const cliArgs = process.argv.slice(2);
32
32
  const devSync = cliArgs.includes('--dev-sync');
33
33
  const releaseChannel = cliArgs.find((a) => !a.startsWith('--'));
34
34
  if (!releaseChannel) {
35
- console.error('Usage: rimori-release <release_channel> [--dev-sync]');
35
+ console.error('Usage: rimori-release stable [--dev-sync]');
36
36
  process.exit(1);
37
37
  }
38
- if (devSync && releaseChannel !== 'alpha') {
39
- console.error('--dev-sync is only allowed with the alpha channel');
38
+ // The alpha channel is retired: it only ever changed which Postgres schema table DDL
39
+ // landed in (`plugins_alpha`), and nothing reads that schema anymore. Releasing alpha
40
+ // would silently migrate tables no app queries, so reject it rather than accept it as
41
+ // a no-op. Config and prompt uploads were never channel-scoped to begin with.
42
+ if (releaseChannel !== 'stable') {
43
+ console.error(`Unknown release channel '${releaseChannel}'. Only 'stable' exists.`);
40
44
  process.exit(1);
41
45
  }
42
46
  const config = {
@@ -54,7 +58,7 @@ const config = {
54
58
  async function releaseProcess() {
55
59
  try {
56
60
  if (config.dev_sync) {
57
- console.log(`⚡ Dev-sync ${config.plugin_id} → existing alpha release`);
61
+ console.log(`⚡ Dev-sync ${config.plugin_id}`);
58
62
  }
59
63
  else {
60
64
  console.log(`🚀 Releasing ${config.plugin_id} to ${config.release_channel}...`);
@@ -12,7 +12,8 @@ export type Plugin<T extends object = object> = Omit<RimoriPluginConfig<T>, 'con
12
12
  */
13
13
  localeUrl?: string;
14
14
  context_menu_actions: MenuEntry[];
15
- release_channel: 'alpha' | 'stable';
15
+ /** Always 'stable' the alpha release channel is retired. */
16
+ release_channel: 'stable';
16
17
  };
17
18
  export type ActivePlugin = Plugin<{
18
19
  active?: boolean;
@@ -30,18 +30,17 @@ export interface RimoriInfo {
30
30
  sidePanelPlugin?: ActivePlugin;
31
31
  interfaceLanguage: string;
32
32
  /**
33
- * The release channel of the plugin installation.
33
+ * The release channel of the plugin installation. Always 'stable' — the alpha channel is
34
+ * retired and kept out of the type so it cannot come back by accident.
34
35
  */
35
- releaseChannel: 'alpha' | 'stable';
36
+ releaseChannel: 'stable';
36
37
  /**
37
- * The database schema to use for plugin tables.
38
- * Determined by rimori-main based on release channel:
39
- * - 'plugins_alpha' for alpha release channel
40
- * - 'plugins' for stable release channel
38
+ * The database schema to use for plugin tables:
39
+ * - 'plugins' for plugin-owned tables
41
40
  * - 'public' for rimori-main's own natively-absorbed features (e.g. studyplan), which own
42
41
  * plain `public` tables namespaced by `tablePrefix` instead of a plugin-scoped schema.
43
42
  */
44
- dbSchema: 'plugins' | 'plugins_alpha' | 'public';
43
+ dbSchema: 'plugins' | 'public';
45
44
  /**
46
45
  * Whether text-to-speech is enabled globally (set in rimori-main navbar).
47
46
  */
@@ -49,7 +49,8 @@ export declare class DbModule {
49
49
  /**
50
50
  * Query a database table.
51
51
  * Global tables (starting with 'global_') remain in public schema.
52
- * Plugin tables use the schema provided by rimori-main (plugins or plugins_alpha).
52
+ * Plugin tables use the schema provided by rimori-main (plugins, or public for rimori-main's
53
+ * own natively-absorbed features).
53
54
  *
54
55
  * The generic parameter `Row` lets callers opt-in to typed row access:
55
56
  * client.db.from<{ id: string; name: string }>('decks')
@@ -16,7 +16,8 @@ export class DbModule {
16
16
  /**
17
17
  * Query a database table.
18
18
  * Global tables (starting with 'global_') remain in public schema.
19
- * Plugin tables use the schema provided by rimori-main (plugins or plugins_alpha).
19
+ * Plugin tables use the schema provided by rimori-main (plugins, or public for rimori-main's
20
+ * own natively-absorbed features).
20
21
  *
21
22
  * The generic parameter `Row` lets callers opt-in to typed row access:
22
23
  * client.db.from<{ id: string; name: string }>('decks')
@@ -19,8 +19,8 @@ export declare class PluginModule {
19
19
  private communicationHandler;
20
20
  private eventBus;
21
21
  /**
22
- * The release channel of this plugin installation.
23
- * Determines which database schema is used for plugin tables.
22
+ * The release channel of this plugin installation. Always 'stable' — release channels are
23
+ * retired and every plugin's tables live in the `plugins` schema.
24
24
  */
25
25
  releaseChannel: string;
26
26
  applicationMode: ApplicationMode;
@@ -11,8 +11,8 @@ export class PluginModule {
11
11
  communicationHandler;
12
12
  eventBus;
13
13
  /**
14
- * The release channel of this plugin installation.
15
- * Determines which database schema is used for plugin tables.
14
+ * The release channel of this plugin installation. Always 'stable' — release channels are
15
+ * retired and every plugin's tables live in the `plugins` schema.
16
16
  */
17
17
  releaseChannel;
18
18
  applicationMode;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rimori/client",
3
- "version": "2.5.49",
3
+ "version": "2.5.50",
4
4
  "main": "dist/index.js",
5
5
  "types": "dist/index.d.ts",
6
6
  "repository": {