Mislav Marohnić
5cd977e328
💅 normalize prompt style for text inputs
2021-12-14 18:38:46 +01:00
Mislav Marohnić
c90fc18b0c
Avoid creating repo when cancelling from interactive mode
2021-12-14 18:18:08 +01:00
Mislav Marohnić
3e40780074
💅 repo create cleanups
2021-12-14 18:05:42 +01:00
Mislav Marohnić
21e6d95982
Fix repo create printing created URL in no-TTY mode
2021-12-14 17:49:43 +01:00
Benjamin Chadwick
6cc7712583
Confirm name change before creating a repo with special characters ( #4562 )
...
Co-authored-by: Mislav Marohnić <mislav@github.com>
2021-11-18 13:24:48 +00:00
Meijke
0a0a358168
rewrite gh repo create ( #4578 )
...
Co-authored-by: Parth Patel <ppatil91099@gmail.com>
2021-11-17 20:16:37 +01:00
Alan Donovan
f4491c7a80
Add FlagErrorf; encapsulate FlagError.error
2021-10-21 11:40:20 -04:00
Mislav Marohnić
ebc1f2f156
Consistently respect GH_HOST in repo archive/create/garden/view commands
2021-10-18 20:05:53 +02:00
Mislav Marohnić
f9e49f4aec
Do not swallow prompt error during repo create
2021-09-16 12:25:44 +02:00
Mislav Marohnić
11fbb60ae7
Rename the module to "github.com/cli/cli/v2"
2021-08-25 12:41:30 +02:00
Mislav Marohnić
6ed2e8f7f8
Add completion support to repo create --gitignore and --license
2021-07-21 16:12:38 +02:00
Mislav Marohnić
1de756f6f3
💅 address review comments
2021-07-20 16:34:11 +02:00
Mislav Marohnić
5c21c949a0
Merge remote-tracking branch 'origin' into fix/private-repo-create
2021-07-15 12:58:00 +02:00
Mislav Marohnić
0ad153f696
Separate payload structs for REST vs GraphQL repo create
...
This enforces strict separation between serialization structs used for
repository creation payload with respect to whether GraphQL or REST was
used. Before, a field added to a GraphQL payload would leak to REST
payload (and vice versa).
2021-07-15 12:56:14 +02:00
Des Preston
17b58bf0b2
fix repo create --confirm
...
Respect the --confirm flag when deciding whether to prompt for gitignore
and license creation during `repo create`
Fixes #3989
2021-07-14 09:59:04 -04:00
Gowtham Munukutla
e600ce054a
fix description related bugs in creating a template repo
2021-07-13 09:38:34 +05:30
Gowtham Munukutla
a1f26057de
gofmt
2021-07-10 23:04:46 +05:30
Gowtham Munukutla
52550f0bee
fix private repo creation in case of ignore templates
2021-07-10 23:03:16 +05:30
vilmibm
589b695bcf
test for org + license/ignore
2021-06-30 17:41:39 -05:00
vilmibm
2723a01760
fix repo generation in org with license/ignore
2021-06-30 17:21:58 -05:00
Gowtham Munukutla
5c7da584e5
clone remote repo after creating with gitignore and license
2021-06-23 10:21:28 +05:30
Gowtham Munukutla
a44a3c8fd0
remove redundant logs
2021-06-17 10:41:24 +05:30
Gowtham Munukutla
137053399e
tweak tests and add extra validations
2021-06-17 10:17:26 +05:30
Gowtham Munukutla
3c8e163e8b
resolve PR comments. Tests WIP
2021-06-16 12:50:05 +05:30
Gowtham Munukutla
5c96d5d460
fix lint errors
2021-05-30 13:53:56 +05:30
Gowtham Munukutla
c4beed8276
complete tests
2021-05-30 13:42:39 +05:30
Gowtham Munukutla
9b87b13b80
add test cases WIP
2021-05-29 19:27:30 +05:30
Sam
9ec1e21d4c
Default to GHES host if only GHES is authenticated ( #3286 )
2021-03-30 16:51:00 +02:00
Mislav Marohnić
9e63199a65
Add tests for checking out repository after creating from template
2021-03-01 14:12:56 +01:00
Mislav Marohnić
e596f8732b
Fix creating a repository from template
...
Fixes a problem where setting up a new local directory for the
repository created from a template would not contain any files:
gh repo create -p OWNER/some-template my-repo --private --confirm
ls my-repo
//=> [empty directory]
Fixes #2290
2021-02-17 20:26:06 +01:00
Mislav Marohnić
a8fdd9a303
Further clarify what will happen on repo create
...
In local git directory:
1. `This will add an "origin" git remote to your local repository. Continue?`
2. "origin" git remote is added in current directory.
Outside of a local git directory:
1. This will create the "REPO" repository on GitHub. Continue?
2. `Create a local project directory for "REPO"?`
3. new directory called "REPO" now set up for the GitHub repository.
2021-02-17 20:22:23 +01:00
ulwlu
95a8f926ab
Remove unnecessary Sprint
2021-02-13 18:10:38 +09:00
ulwlu
16be90c538
Fix unnecessary Sprintf with Sprint
2021-02-13 17:20:39 +09:00
ulwlu
e461baa217
Fix prompt string when creating remote repository
...
If you are in git project not pushed to remote yet,
prompt says 'This will create {reponame} in current directory. Continue?',
however, it doesn't create while it only adds remote origin.
I was going to create PR to avoid creating new directory before I knew
this behavior.
This behavior is already ideal, so I changed prompt not to scare users
like I got scared.
2021-02-13 17:11:08 +09:00
Mislav Marohnić
ab21dbeaf0
Improve repo create docs
...
- Clarify what will happen when in the git directory vs. out;
- List requirements for non-interactive use;
- Demonstrate how to turn issues/wiki off.
- Misc. formatting tweaks
2021-02-03 22:05:06 +01:00
Devon Romanko
2964895a77
fix test behavior changes from migration to run.Stub
2021-01-27 18:46:29 -05:00
Devon Romanko
696cbfc8d1
use Stub instead of SetPrepareCmd in 'repo create' tests
2021-01-27 07:59:32 -05:00
Mislav Marohnić
f46bab256c
Rename to SuccessIconWithColor
2021-01-25 14:56:39 +01:00
Mislav Marohnić
96fa6e7830
Merge remote-tracking branch 'origin' into success-icon-consistency
2021-01-22 23:56:54 +01:00
Mislav Marohnić
23d68705bc
Match color of the success icon with the end state of the record
2021-01-22 23:55:33 +01:00
Mislav Marohnić
06cf2c9f81
Merge remote-tracking branch 'origin' into cmd-stub-new
2021-01-22 16:31:29 +01:00
vilmibm
3797aa72ff
delete unused parameter
2021-01-19 19:08:49 -08:00
Mislav Marohnić
c308f1cd91
Prevent further use of SetPrepareCmd and InitCmdStubber
2021-01-18 22:44:53 +01:00
Cristian Dominguez
ce151420f3
Migrate legacy tests
2021-01-11 21:07:19 -03:00
xhqr
8b5c5896f2
[repo/create] Create local repo dir with non tty. ( #2671 )
...
This addresses issue #2587 .
2021-01-05 14:40:52 -08:00
Josh Soref
e58b2dbe92
spelling: chestnuts
2020-11-21 21:43:51 -05:00
Mislav Marohnić
5b4a08dcb9
Ensure that only PATH is searched when shelling out to external commands
...
Works around https://github.com/golang/go/issues/38736 for Windows.
2020-11-11 16:33:13 +01:00
vilmibm
a2aa154794
port entirely to ColorScheme
2020-10-29 12:37:45 -07:00
Sam Coe
458d5cb42f
Respect interactive repo name input on create
2020-09-21 14:26:15 +02:00
Mislav Marohnić
f9239661f2
Reuse the StubRepoInfoReponse test helper
2020-09-16 15:01:13 +02:00