Re: Pull a single file using git lfs


Andy Pont
 

I wrote...

Unfortunately, there are other files in the same directory that can’t be checked out. Looking at that documentation, I have added the “nocheckout=1” option to the git definition in SRC_URI which is stopping the initial pull.

When I try to add any git commands into a do_fetch_append() then it dumps a load of Python looking stuff on the screen that ends with:

  File "autogenerated", line 4
    git lfs checkout build/filename
               ^
SyntaxError: invalid syntax
So, do_fetch() is a Python function and you can’t run shell commands in it.  That is fine, I have let it do its thing to initialise the git repository and moved my custom commands into a do_configure() to replace the standard one.

It will pull a single file out of the repo using "git checkout master <filename>” but is having difficulties with “git lfs …” commands.  That though looks like an issue there not with the bitbake recipe per-se.

-Andy.


Join yocto@lists.yoctoproject.org to automatically receive all group messages.