@13w/miri 1.1.16 → 1.1.17

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/dist/cli.js CHANGED
@@ -1,15 +1,14 @@
1
1
  import { readFileSync, realpathSync } from 'node:fs';
2
2
  import { readFile } from 'node:fs/promises';
3
- Error.stackTraceLimit = Infinity;
4
3
  import { join } from 'node:path';
5
- /* eslint-disable no-console */
4
+ Error.stackTraceLimit = Infinity;
5
+ import colors from 'colors';
6
6
  import { Command } from 'commander';
7
7
  import { Table } from 'console-table-printer';
8
- import colors from 'colors';
9
- import { createTunnel } from 'tunnel-ssh';
10
8
  import SSHConfig from 'ssh-config';
11
- import connection from './mongodb.js';
9
+ import { createTunnel } from 'tunnel-ssh';
12
10
  import Miri, { IndexStatus, PatchStatus } from './miri.js';
11
+ import connection from './mongodb.js';
13
12
  const pkg = await readFile(join(import.meta.dirname, '../package.json'), 'utf-8').then((content) => JSON.parse(content));
14
13
  const mirirc = await readFile(join(process.cwd(), '.mirirc'), 'utf-8').then((content) => JSON.parse(content), () => ({}));
15
14
  const { SSH_AUTH_SOCK, HOME } = process.env;
@@ -41,6 +40,7 @@ const askPassword = async (message = 'Password: ') => {
41
40
  // Ctrl C
42
41
  process.stdin.off('data', readPass);
43
42
  reject(new Error('Cancelled'));
43
+ return;
44
44
  default:
45
45
  // More passsword characters
46
46
  password += str;
@@ -100,7 +100,7 @@ const createSSHTunnel = async (opts) => {
100
100
  else if (SSH_AUTH_SOCK) {
101
101
  sshOptions.agent = SSH_AUTH_SOCK;
102
102
  }
103
- console.dir([config, sshOptions]);
103
+ // console.dir([config, sshOptions])
104
104
  const dst = new URL(config.db);
105
105
  const forwardOptions = {
106
106
  dstPort: Number(dst.port ?? 27017),
package/dist/evaluator.js CHANGED
@@ -1,4 +1,3 @@
1
- /* eslint-disable no-console */
2
1
  import { EventEmitter } from 'node:events';
3
2
  import { createContext, runInContext, SourceTextModule, SyntheticModule } from 'node:vm';
4
3
  import { inspect } from 'node:util';
@@ -46,7 +45,7 @@ export async function evaluateMongo(client, code, filename = '[no file]') {
46
45
  onLoad() {
47
46
  throw new Error('Load isn\'t supported');
48
47
  },
49
- async onExit() {
48
+ onExit() {
50
49
  throw new Error('Exit isn\'t supported');
51
50
  },
52
51
  });
package/dist/miri.js CHANGED
@@ -1,4 +1,3 @@
1
- /* eslint-disable no-console */
2
1
  import { createHash } from 'node:crypto';
3
2
  import { readdir, readFile, realpath } from 'node:fs/promises';
4
3
  import { resolve, extname, basename } from 'node:path';
package/dist/mongodb.js CHANGED
@@ -1,4 +1,3 @@
1
- /* eslint-disable no-console */
2
1
  import { MongoClient } from 'mongodb';
3
2
  let client;
4
3
  export default async function connect(uri = 'mongodb://localhost:27017/test') {
package/package.json CHANGED
@@ -1,10 +1,10 @@
1
1
  {
2
2
  "name": "@13w/miri",
3
3
  "description": "MongoDB patch manager",
4
- "version": "1.1.16",
4
+ "version": "1.1.17",
5
5
  "type": "module",
6
6
  "engines": {
7
- "node": "v20"
7
+ "node": "v22"
8
8
  },
9
9
  "keywords": [
10
10
  "MongoDB",
@@ -25,29 +25,29 @@
25
25
  "main": "bin/miri",
26
26
  "types": "types/miri.d.ts",
27
27
  "dependencies": {
28
- "@mongosh/service-provider-server": "^2.2.15",
29
- "@mongosh/shell-api": "^2.2.15",
30
- "@mongosh/shell-evaluator": "^2.2.15",
28
+ "@mongosh/service-provider-server": "^2.3.1",
29
+ "@mongosh/shell-api": "^2.3.1",
30
+ "@mongosh/shell-evaluator": "^2.3.1",
31
31
  "colors": "^1.4.0",
32
32
  "commander": "^12.1.0",
33
33
  "console-table-printer": "^2.12.1",
34
- "mongodb": "^6.8.0",
35
- "ssh-config": "^4.4.4",
34
+ "mongodb": "^6.9.0",
35
+ "ssh-config": "^5.0.0",
36
36
  "tunnel-ssh": "^5.1.2"
37
37
  },
38
38
  "devDependencies": {
39
- "@types/node": "^20.14.15",
40
- "@typescript-eslint/eslint-plugin": "^7.18.0",
41
- "@typescript-eslint/parser": "^7.18.0",
42
- "eslint": "^8.57.0",
43
- "eslint-plugin-deprecation": "^2.0.0",
39
+ "@eslint/js": "^9.10.0",
40
+ "@types/node": "^22.5.5",
41
+ "eslint": "^9.10.0",
42
+ "mongodb-log-writer": "^1.4.2",
44
43
  "ts-node": "^10.9.2",
45
- "typescript": "^5.5.4"
44
+ "typescript": "^5.6.2",
45
+ "typescript-eslint": "^8.5.0"
46
46
  },
47
47
  "license": "MIT",
48
48
  "scripts": {
49
49
  "build": "tsc -p tsconfig.json",
50
- "lint": "eslint src/ --ext .ts --quiet",
50
+ "lint": "eslint --quiet src/",
51
51
  "prepublish": "pnpm run build"
52
52
  }
53
53
  }