1

How can I get the code from latest release of a Github repository using nodegit?

I went through this API guide. I also look around in nodegit user guides. There are examples to get the latest commit - but not the latest release.

Note: I would like to use nodegit instead of github's api because I would like to make my code work with an internal git repository at a later point in time.

user1700184
  • 1,611
  • 2
  • 16
  • 23

1 Answers1

1

This is what I ended up doing:

  1. Git clone to a common location, if this is the first time I am executing. Example from nodegit.
  2. Git fetch on the location, for subsequent runs.

Once the repository is cloned to local machine, we can get the latest release from there to whichever work-space directory that we need it at.

user1700184
  • 1,611
  • 2
  • 16
  • 23