Skip to content

Add second param that indicates whether repo was cloned or pulled #23

Description

@davej

Usage would look like this:

const cloneOrPull = require('git-clone-or-pull')

cloneOrPull('git@github.com:feross/standard.git', '/path/to/destination', (err, action) => {
  if (err) throw err
  console.log(action) // -> 'clone'

  cloneOrPull('git@github.com:feross/standard.git', '/path/to/destination', (err, action) => {
    if (err) throw err
    console.log(action) // -> 'pull'
  })

})

What do you think? It would also be non-breaking which is a bonus.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions