Skip to content

Commit a07bf2d

Browse files
authored
Merge pull request #22 from NomarCub/feature/url-protocol-string
Remove the useUrlInsiders: boolean setting in favor of a more general urlProtocol: string. This makes using other VSCode forks easier. Migrate the old option on startup.
2 parents ad0bdeb + 31ba6cb commit a07bf2d

File tree

7 files changed

+1380
-461
lines changed

7 files changed

+1380
-461
lines changed

README.md

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -40,20 +40,21 @@ See also: [VSCode CLI - Opening Files and Folders](https://code.visualstudio.com
4040

4141
### Settings for `open-vscode-via-url`
4242

43-
On some systems, this may be faster than using the `child_process` approach.
43+
On some systems, this may be faster than using the `child_process` approach.
44+
See: [Opening VS Code with URLs](https://code.visualstudio.com/docs/editor/command-line#_opening-vs-code-with-urls).
45+
The first time you use the URL method for opening, VSCode displays a confirmation dialog (that you just can hit enter on) for security reasons.
4446

45-
- **Open file**
47+
- **Open current file**
4648

4749
Open the current file rather than the root of the Obsidian vault.
4850

4951
- **Path to VSCode Workspace**
5052

5153
Defaults to the `{{vaultpath}}` template variable. You can set this to an absolute path to a ".code-workspace" file if you prefer to use a [multi-root workspace](https://code.visualstudio.com/docs/editor/workspaces#_multiroot-workspaces).
5254

53-
- **Open VSCode using a `vscode://` URL**
55+
- **URL protocol**
5456

55-
See: [Opening VS Code with URLs](https://code.visualstudio.com/docs/editor/command-line#_opening-vs-code-with-urls).
56-
The first time you use the URL method for opening, VSCode displays a confirmation dialog (that you just can hit enter on) for security reasons.
57+
You can override the default `vscode://` to VSCode Insiders, VSCodium or other VSCode variants' protocol string.
5758

5859
## Installation
5960

eslint.config.mjs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ export default tseslint.config({
88
eslint.configs.recommended,
99
tseslint.configs.strictTypeChecked,
1010
tseslint.configs.stylisticTypeChecked,
11-
stylistic.configs["recommended-flat"],
11+
stylistic.configs.recommended,
1212
],
1313
languageOptions: {
1414
parserOptions: { projectService: true, project: true },

manifest.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"id": "open-vscode",
33
"name": "Open vault in VSCode",
4-
"version": "1.3.0",
4+
"version": "1.4.0",
55
"minAppVersion": "1.7.2",
66
"description": "Ribbon button, command and file explorer context menu to open the vault as a Visual Studio Code (VSCode) workspace",
77
"author": "NomarCub",

0 commit comments

Comments
 (0)