Skip to content

Abort on getRemotes #201

@unRob

Description

@unRob

Assuming the following repo:

cd /tmp
mkdir nodegit-test
cd nodegit-test
git init .
touch 'test'
git commit -m 'first commit'
git remote add origin [email protected]:example/example.git

Running repo.getRemotes(function(err, remotes) will result on [1] 39497 abort node test.js with the following code:

git = require('nodegit')

git.Repo.open('/tmp/nodegit-test/.git', function(err, repo){
  if (err) {
    console.error(err);
    process.exit(1);
  }

  repo.getRemotes(function(err, remotes){
    // the following will never get called
    console.log(err)
    console.log(remotes)
  });
});

This is on OSX 10.9.4, and git --version = 2.0.1.

I'm hoping it's me doing something the wrong way, but if the repo has no remotes, then an empty array is returned without any problems.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions