question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Support 'depth' in cloneOptions

See original GitHub issue

I’m using nodegit to automate the setup process of a large project with many dependencies. I’d like to be able to reduce the time it takes to clone some of the repositories by limiting the clone to the last 200 revisions, but nodegit does not support the depth option as far as I can tell.

Example git command:

git clone --depth 200 path/to/repo.git 

Issue Analytics

  • State:closed
  • Created 8 years ago
  • Reactions:4
  • Comments:5 (1 by maintainers)

github_iconTop GitHub Comments

2reactions
WORMSScommented, Sep 13, 2016

Shouldn’t this still be open but with a RequiresUpstream label or something?

0reactions
maxkorpcommented, Oct 22, 2018

@Hatko I only did a cursory search of the libgit2 api docs here by doing a text search for depth, as well as a quick glance at the git_clone_options struct, but yeah, I don’t see any sign of depth support. It would be worth asking in the libgit2 slack.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Support for more clone options at the step level - Bitbucket
lfs controls whether files that have been checked in with Git LFS are checked out, while depth controls how much history is cloned....
Read more >
git-clone Documentation - Git
All submodules which are cloned will be shallow with a depth of 1. ... The ssh and git protocols additionally support ~username expansion:....
Read more >
How to Use Git Shallow Clone to Improve Performance
How to Execute Git Shallow Clone. Provide an argument of -- depth 1 to the git clone command to copy only the latest...
Read more >
Get up to speed with partial clone and shallow clone
Shallow clones use the --depth=<N> parameter in git clone to truncate ... different clone options on a variety of open source repositories.
Read more >
[JENKINS-24728] Add ability to specify shallow clone depth
If you could add the ability to specify a depth value for cloning that ... src/main/resources/hudson/plugins/git/extensions/impl/CloneOption/help-depth.html
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found