@inquirer/external-editor 3.0.3 → 3.0.5

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
@@ -77,6 +77,19 @@ try {
77
77
  }
78
78
  ```
79
79
 
80
+ ### Windows editor commands
81
+
82
+ On Windows, prefer setting `$VISUAL` or `$EDITOR` to the editor executable
83
+ rather than a `.cmd` or `.bat` shim. This package launches the editor directly
84
+ instead of through a shell so editor arguments and temporary file paths are not
85
+ interpreted as shell commands.
86
+
87
+ For example, use `Code.exe` with `--wait` instead of `code.cmd`:
88
+
89
+ ```powershell
90
+ setx VISUAL '"C:\Program Files\Microsoft VS Code\Code.exe" --wait'
91
+ ```
92
+
80
93
  #### API
81
94
 
82
95
  **Convenience Functions**
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@inquirer/external-editor",
3
- "version": "3.0.3",
3
+ "version": "3.0.5",
4
4
  "description": "Edit a string with the users preferred text editor using $VISUAL or $ENVIRONMENT",
5
5
  "keywords": [
6
6
  "answer",
@@ -76,8 +76,9 @@
76
76
  "iconv-lite": "^0.7.2"
77
77
  },
78
78
  "devDependencies": {
79
+ "@repo/tsconfig": "0.0.0",
79
80
  "@types/chardet": "^1.0.0",
80
- "@types/node": "^25.5.2",
81
+ "@types/node": "^26.1.1",
81
82
  "typescript": "^6.0.2"
82
83
  },
83
84
  "peerDependencies": {
@@ -93,5 +94,5 @@
93
94
  },
94
95
  "main": "./dist/index.js",
95
96
  "types": "./dist/index.d.ts",
96
- "gitHead": "bfd8710229e3d3c9784bef3bbfbd84c7bd09bb9e"
97
+ "gitHead": "5748bd9966b5e175ddf5995ee4cdce6f60c4272e"
97
98
  }
@@ -1,10 +0,0 @@
1
- /***
2
- * Node External Editor
3
- *
4
- * Kevin Gravier <kevin@mrkmg.com>
5
- * MIT 2018
6
- */
7
- export declare class CreateFileError extends Error {
8
- originalError: Error;
9
- constructor(originalError: Error);
10
- }
@@ -1,13 +0,0 @@
1
- /***
2
- * Node External Editor
3
- *
4
- * Kevin Gravier <kevin@mrkmg.com>
5
- * MIT 2018
6
- */
7
- export class CreateFileError extends Error {
8
- originalError;
9
- constructor(originalError) {
10
- super(`Failed to create temporary file. ${originalError.message}`);
11
- this.originalError = originalError;
12
- }
13
- }
@@ -1,10 +0,0 @@
1
- /***
2
- * Node External Editor
3
- *
4
- * Kevin Gravier <kevin@mrkmg.com>
5
- * MIT 2018
6
- */
7
- export declare class LaunchEditorError extends Error {
8
- originalError: Error;
9
- constructor(originalError: Error);
10
- }
@@ -1,13 +0,0 @@
1
- /***
2
- * Node External Editor
3
- *
4
- * Kevin Gravier <kevin@mrkmg.com>
5
- * MIT 2018
6
- */
7
- export class LaunchEditorError extends Error {
8
- originalError;
9
- constructor(originalError) {
10
- super(`Failed to launch editor. ${originalError.message}`);
11
- this.originalError = originalError;
12
- }
13
- }
@@ -1,10 +0,0 @@
1
- /***
2
- * Node External Editor
3
- *
4
- * Kevin Gravier <kevin@mrkmg.com>
5
- * MIT 2018
6
- */
7
- export declare class ReadFileError extends Error {
8
- originalError: Error;
9
- constructor(originalError: Error);
10
- }
@@ -1,13 +0,0 @@
1
- /***
2
- * Node External Editor
3
- *
4
- * Kevin Gravier <kevin@mrkmg.com>
5
- * MIT 2018
6
- */
7
- export class ReadFileError extends Error {
8
- originalError;
9
- constructor(originalError) {
10
- super(`Failed to read temporary file. ${originalError.message}`);
11
- this.originalError = originalError;
12
- }
13
- }
@@ -1,10 +0,0 @@
1
- /***
2
- * Node External Editor
3
- *
4
- * Kevin Gravier <kevin@mrkmg.com>
5
- * MIT 2018
6
- */
7
- export declare class RemoveFileError extends Error {
8
- originalError: Error;
9
- constructor(originalError: Error);
10
- }
@@ -1,13 +0,0 @@
1
- /***
2
- * Node External Editor
3
- *
4
- * Kevin Gravier <kevin@mrkmg.com>
5
- * MIT 2018
6
- */
7
- export class RemoveFileError extends Error {
8
- originalError;
9
- constructor(originalError) {
10
- super(`Failed to remove temporary file. ${originalError.message}`);
11
- this.originalError = originalError;
12
- }
13
- }