Skip to content
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

Space in path will not break the bootstrap command #78

Merged
merged 1 commit into from
May 4, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions lib/commands/bootstrap.js
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,8 @@ module.exports = {
promise = Promise.resolve();
} else {
const command = [
`git clone --progress ${ data.repository.url } ${ destinationPath }`,
`cd ${ destinationPath }`,
`git clone --progress "${ data.repository.url }" "${ destinationPath }"`,
`cd "${ destinationPath }"`,
`git checkout --quiet ${ data.repository.branch }`
].join( ' && ' );

Expand Down
4 changes: 2 additions & 2 deletions tests/commands/bootstrap.js
Original file line number Diff line number Diff line change
Expand Up @@ -88,9 +88,9 @@ describe( 'commands/bootstrap', () => {

// Clone the repository.
expect( cloneCommand[ 0 ] )
.to.equal( 'git clone --progress git@github.com/organization/test-package.git packages/test-package' );
.to.equal( 'git clone --progress "git@github.com/organization/test-package.git" "packages/test-package"' );
// Change the directory to cloned package.
expect( cloneCommand[ 1 ] ).to.equal( 'cd packages/test-package' );
expect( cloneCommand[ 1 ] ).to.equal( 'cd "packages/test-package"' );
// And check out to proper branch.
expect( cloneCommand[ 2 ] ).to.equal( 'git checkout --quiet master' );

Expand Down