kahole / edamagit

Magit for VSCode

Home Page:https://marketplace.visualstudio.com/items?itemName=kahole.magit

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Confirm Clone functionality not available

HughKelley opened this issue · comments

Thanks very much for your work on this. I wanted to confirm that consistent with my search of the repo and documentation, Cloning a new repo is not currently possible with edamagit.

In a perfect world I would be able to contribute a pr with that functionality but that isn't an option with my current workload. Thanks for confirming that I haven't missed anything if possible!

You are right, there is no edamagit functionality for cloning.
You could maybe get by using the vscode "Git Clone"-command.
Have you tried it?
You could make it available inside the status-buffer as a keybind also, or it could even be added as a default in edamagit, until the real cloning edamagit functionality is made.

yeah it's definitely possible.

I think it might deserve some more thought. One complication is that the VS code window is project/repository specific, whereas the Emacs instance spans multiple repositories easily. I'm not that the status buffer would be the most logical or intuitive place for it.

In emacs I hit C-x M-g to bring up the global git options buffer and then clone. i'm not sure whether that would be appropriate though either and it would be a lot more work to create a new buffer view.

I'll continue to give it some thought and maybe make a PR down the road. I'm just recently switching over to VS Code so still finding my way.

Just to close the loop on this in case someone else comes across it.

Unlike emacs, a vscode window is generally specific to a single project, which to some extent presents a problem for cloning within eda-magit.

My current solution is to just use the built in git commands in vscode, with an emacs style keybinding from magit.

To set the keybinding:

  • use Control Shift P to open the vscode commands search interface.
  • Search for "clone"
  • Click the gear to "configure keybinding"
  • click the cell in the "keybinding" column
  • press Alt X Shift C (emacs M-C for cloning in magit) or whatever other keybinding you want

The full work flow is M-x C, paste the ssh link, Enter. Control Shift N to open a new window, Control K O to open a new directory.

image