-
Notifications
You must be signed in to change notification settings - Fork 343
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Refactor out git_init() #2807
Refactor out git_init() #2807
Conversation
bc2eb71
to
2848341
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- Add Workspace::create_workspace_root() which is needed by all init functionality regardless of the backend.
- Move canonicalization of the external git repo path into the Workspace::init_git_external(). This keeps necessary code together.
- Create a git_init() function in cli/src/commands/init.rs where all git related work is done. This function will be moved to cli/src/commands/git.rs in a subsequent PR.
- Add a new variant of WorkspaceInitError for reporting path not found errors. The user error string is written to pass existing tests.
If you have some of these as separate commits, can you send them without squashing? It's a bit hard to review code move including changes.
2848341
to
ac52647
Compare
I've split these up now. Thanks for prompting. I've stacked the changes up nicely, which means that this PR now has a different base CL than |
3a6db44
to
938bf01
Compare
ac52647
to
1325bd0
Compare
47ae233
to
b284701
Compare
4a52f92
to
8b9db06
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm, thanks!
b284701
to
189978b
Compare
8b9db06
to
0995d64
Compare
5041ec2
to
a85fcde
Compare
* Create a git_init() function in cli/src/commands/init.rs where all git related work is done. This function will be moved to cli/src/commands/git.rs in a subsequent PR.
Checklist
If applicable: