8

I am using Git LFS with Bitbucket using OSX (although i found the same issue with Ubuntu).

My repo contains many files stored using Git LFS

When I do a git clone, it asks for my passphrase for EVERY tracked file using Git LFS. This is a huge issue as I can have potentially hundreds of files stored using Git LFS.

Note that there is no problems regarding files that are not tracked using Git LFS.

How can I fix this issue?

Yahya Uddin
  • 26,997
  • 35
  • 140
  • 231

2 Answers2

7

I knew I read about this on the tutorial page.

"Since git-lfs only supports http/https, git will need to authenticate over http/https when pushing files, even if you are using ssh/git protocol for git. Without the credential helper, you will be asked to enter your username and password for EVERY connection, which is pretty unusable. To get around this, git credential helpers will help handling passwords for you."

You can find all the info you need here

5

Update

As @Gabriel mentioned, you should now just use the usual:

  • git clone
  • git pull

Old Answer (Deprecated)

I am surprised that other people did not have this question.

The answer is to use:

  • git lfs clone instead of git clone
  • git lfs pull instead of git pull

This also improves performance by using parallelisation.

For more information, see: https://www.atlassian.com/git/tutorials/git-lfs#speeding-up-clones

Yahya Uddin
  • 26,997
  • 35
  • 140
  • 231