diff --git a/Dockerfile b/Dockerfile index d49271fa30f..6a817b37c61 100644 --- a/Dockerfile +++ b/Dockerfile @@ -16,6 +16,7 @@ RUN apt-get update \ build-essential \ dirmngr \ git \ + git-lfs \ bzr \ mercurial \ gnupg2 \ @@ -315,3 +316,5 @@ RUN curl -sL $SHIM -o git-shim.tar.gz && mkdir -p ~/bin && tar -xvf git-shim.tar ENV PATH="$HOME/bin:$PATH" # Configure cargo to use git CLI so the above takes effect RUN mkdir -p ~/.cargo && printf "[net]\ngit-fetch-with-cli = true\n" >> ~/.cargo/config.toml +# Disable automatic pulling of files stored with Git LFS +ENV GIT_LFS_SKIP_SMUDGE=1 diff --git a/npm_and_yarn/lib/dependabot/npm_and_yarn/file_updater/yarn_lockfile_updater.rb b/npm_and_yarn/lib/dependabot/npm_and_yarn/file_updater/yarn_lockfile_updater.rb index 26d2ed2d8d8..5801ef116e7 100644 --- a/npm_and_yarn/lib/dependabot/npm_and_yarn/file_updater/yarn_lockfile_updater.rb +++ b/npm_and_yarn/lib/dependabot/npm_and_yarn/file_updater/yarn_lockfile_updater.rb @@ -55,6 +55,8 @@ def sub_dependencies def updated_yarn_lock(yarn_lock) base_dir = dependency_files.first.directory SharedHelpers.in_a_temporary_repo_directory(base_dir, repo_contents_path) do + # Pull any yarn data or plugins which may be stored with Git LFS + SharedHelpers.run_shell_command("git lfs pull --include .yarn") write_temporary_dependency_files lockfile_name = Pathname.new(yarn_lock.name).basename.to_s path = Pathname.new(yarn_lock.name).dirname.to_s