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

Attempt a checkout before pulling remote #15

Merged
merged 1 commit into from
Mar 21, 2016
Merged

Conversation

e-dard
Copy link
Contributor

@e-dard e-dard commented Mar 21, 2016

Rather than attempting to fetch the dependency remotely and then
checking out the revision, the opposite will now happen.

First, gdm will attempt to checkout the correct revision, and on error
the latest changes of the dependency will be fetched, and the checkout
re-attempted.

This has two advantages:

  1. It allows us to make a private dependency available to gdm without
    gdm attempting to fetch it.
  2. It's more efficient in the common case that the working tree has
    the dependency available locally with the desired revision.

Rather than attempting to fetch the dependency remotely and then
checking out the revision, the opposite will now happen.

First, gdm will attempt to checkout the correct revision, and on error
the latest changes of the dependency will be fetched and the checkout
re-attempted.

This has two advantages:

 1. It allows us to make a private dependency available to gdm without
    gdm attempting to fetch it.
 2. It's more efficient in the common case that the working tree has
    the dependency available locally with the desired revision.
@sparrc
Copy link
Owner

sparrc commented Mar 21, 2016

good idea, thanks @e-dard! :partyparrot:

@sparrc sparrc merged commit f03a1f6 into sparrc:master Mar 21, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants