I want to get source code of some Qt modules. I don't need change history and most of Qt submodules so I decided to clone Qt Git repo and init & update some modules:
git clone --branch v5.10.1 --depth 1 git://code.qt.io/qt/qt5.git source
cd source
git submodule update --init --depth 1 qtbase qtlocation
However, when I'm trying to run code above it gives me following error:
fatal: The remote end hung up unexpectedly
Fetched in submodule path 'qtbase', but it did not contain 6c6ace9d23f90845fd424e474d38fe30f070775e. Direct fetching of that commit failed.
If I'm trying to init & update all submodules, it works:
git clone --branch v5.10.1 --depth 1 git://code.qt.io/qt/qt5.git source
cd source
git submodule update --init --depth 1
How can I get source code of git repo including some submodules without version history?