Skip to content

Commit

Permalink
Move command client into core folder (talonhub#1678)
Browse files Browse the repository at this point in the history
The reason the command client resides in the vscode folder is because it
was designed for vscode originally, but now it's actually used for more
applications so I'm moving it to the core folder instead.

I will take care of the subtree. I have successfully run the split
command on my computer.
  • Loading branch information
AndreasArvidsson authored Jan 13, 2025
1 parent 0f08fb8 commit 2100ebc
Show file tree
Hide file tree
Showing 13 changed files with 9 additions and 20 deletions.
3 changes: 3 additions & 0 deletions apps/visualstudio/visual_studio.py
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,9 @@ def filename():

@ctx.action_class("user")
class UserActions:
def command_server_directory() -> str:
return "visual-studio-command-server"

# def select_word(verb: str):
# actions.key("ctrl-w")
# actions.user.perform_selection_action(verb)
Expand Down
1 change: 1 addition & 0 deletions apps/visualstudio/visual_studio.talon
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ tag(): user.tabs
tag(): user.line_commands
tag(): user.find_and_replace
tag(): user.multiple_cursors
tag(): user.command_client

# Panels
panel solution: key(ctrl-alt-l)
Expand Down
15 changes: 0 additions & 15 deletions apps/vscode/command_client/visual_studio.py

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@

from talon import Context, Module, actions

from .command_client import NotSet, run_command
from .rpc_client.types import NoFileServerException
from ...core.command_client.command_client import NotSet, run_command
from ...core.command_client.rpc_client.types import NoFileServerException

mod = Module()

Expand Down
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
# Talon VSCode command client
# Talon command client

This directory contains the client code for communicating with the [VSCode command server](https://marketplace.visualstudio.com/items?itemName=pokey.command-server).

## Contributing

The source of truth is in /~https://github.com/talonhub/community/tree/main/apps/vscode/command_client, but the code is also maintained as a subtree at /~https://github.com/cursorless-dev/talon-command-client.
The source of truth is in /~https://github.com/talonhub/community/tree/main/core/command_client, but the code is also maintained as a subtree at /~https://github.com/cursorless-dev/talon-command-client.

To contribute, first open a PR on `community`.

Once the PR is merged, you can push the changes to the subtree by running the following commands on an up-to-date `community` main: (need write access)

```sh
git subtree split --prefix=apps/vscode/command_client --annotate="[split] " -b split
git subtree split --prefix=core/command_client --annotate="[split] " -b split
git push git@github.com:cursorless-dev/talon-command-client.git split:main
```
File renamed without changes.
File renamed without changes.
File renamed without changes.

0 comments on commit 2100ebc

Please sign in to comment.