Commit graph

15 commits

Author SHA1 Message Date
Caleb Brose
c9992b41a2
Always open new vscode window in gh cs code (#7092)
* Open new vscode window

* Tests
2023-03-06 22:50:43 +00:00
Caleb Brose
57c73e8239
Add --repo filter to more gh codespaces commands (#6669)
* Add --repo flag to commands

* Example of using common args

* Add -r to stop

* Add validation to the add helper

* Skip prompt for single option

* Migrate (mostly) everything to addGetOrChooseCodespaceCommandArgs

* Fix typo in logsCmd

* Use R instead of r

* Update a couple -r usages

* Refactor to codespace_selector

* Clean up selector, apply it in a couple examples

* Use apiClient instead in constructor

* Restore addDeprecatedRepoShorthand

* Finish implementing the commands

* Update existing tests to use the selector

* Add tests for selector

* linter

* Catch case where there's no conflict

* Make the flag persistent for ports

* Add support to stop
2023-02-22 17:16:36 -06:00
Robin Neatherway
78fb90956c
Teach gh cs create to use current repo as default (#6596)
Co-authored-by: Mislav Marohnić <mislav@github.com>
2023-02-07 20:05:38 +00:00
Caleb Brose
0c00ca911e Clean up API interface 2022-09-16 22:25:11 +00:00
Caleb Brose
6b24949649
Merge pull request #5958 from cli/cmbrose/no-auto-key-if-uploaded
Check for already configured ssh keys before using automatic key
2022-08-23 12:09:16 -05:00
Sam Coe
6a8deb1f5a
Integrate latest go-gh packages (#6084) 2022-08-18 09:04:13 +03:00
Caleb Brose
88b28c5228 Fix api mock 2022-08-02 20:57:52 +00:00
Håvard Anda Estensen
58cb773e09
Replace ioutil with io and os (#5498) 2022-04-26 13:07:44 +02:00
Jack Meyer
ce0562c5f2
Add codespace open --web flag (#5380)
Co-authored-by: Luan Vieira <luanzeba@github.com>
Co-authored-by: Mislav Marohnić <mislav@github.com>
2022-04-11 19:09:27 +02:00
Charlie Andrews
64eecef176 Remove unhelpful error wrapper 2022-03-16 09:36:14 -04:00
Charlie Andrews
a2f76fdfe0 Fix copy pasta error to appease the linter 2022-03-16 09:10:54 -04:00
Charlie Andrews
8bf0cb8f13 Refactor the getOrChooseCodespace to always check for pending ops 2022-03-16 08:56:17 -04:00
Charlie Andrews
f94a1a2bd4 Add test for disallowing opening vs code for codespace with pending op
I also refactored the existing vs code test a bit to work with the new
use of `getOrChooseCodespace`.
2022-03-15 17:27:38 -04:00
Mark Phelps
590acaa1d6 WIP 2022-02-15 19:35:53 -05:00
Mislav Marohnić
a573eb5d80
Fix codespace code command under WSL (#4747)
The `codespace code` command used the `skratchdot/open-golang` library
to open `vscode://` URLs, which uses `xdg-open` for Linux under the
hood, which isn't available under WSL.

This switches over to using the `cli/browser` package which has explicit
support for WSL by invoking `wslview` when found.
2021-11-24 16:18:24 +00:00