Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Do a shallow git fetch instead of full fetch #11041

Merged
merged 1 commit into from
Oct 29, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions scripts/patch-realsense-ubuntu-lts-hwe.sh
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,7 @@ then
kernel_git_tag=$(git ls-remote --tags origin | grep "${kernel_full_num}\." | grep '[^^{}]$' | head -n 1 | awk -F/ '{print $NF}')
fi
echo -e "\e[32mFetching Ubuntu LTS tag \e[47m${kernel_git_tag}\e[0m \e[32m to the local kernel sources folder\e[0m"
git fetch origin tag ${kernel_git_tag} --no-tags
git fetch origin tag ${kernel_git_tag} --no-tags --depth 1

# Verify that there are no trailing changes., warn the user to make corrective action if needed
if [ $(git status | grep 'modified:' | wc -l) -ne 0 ];
Expand Down Expand Up @@ -153,7 +153,7 @@ then


if [ $reset_driver -eq 1 ];
then
then
echo -e "\e[43mUser requested to rebuild and reinstall ubuntu-${ubuntu_codename} stock drivers\e[0m"
else
# Patching kernel for RealSense devices
Expand Down
4 changes: 2 additions & 2 deletions scripts/patch-realsense-ubuntu-lts.sh
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ then
kernel_full_num=$(echo $LINUX_BRANCH | cut -d '-' -f 1,2)
kernel_git_tag=$(git ls-remote --tags origin | grep "${kernel_full_num}\." | grep '[^^{}]$' | tail -n 1 | awk -F/ '{print $NF}')
echo -e "\e[32mFetching Ubuntu LTS tag \e[47m${kernel_git_tag}\e[0m \e[32m to the local kernel sources folder\e[0m"
git fetch origin tag ${kernel_git_tag} --no-tags
git fetch origin tag ${kernel_git_tag} --no-tags --depth 1

# Verify that there are no trailing changes., warn the user to make corrective action if needed
if [ $(git status | grep 'modified:' | wc -l) -ne 0 ];
Expand Down Expand Up @@ -144,7 +144,7 @@ then


if [ $reset_driver -eq 1 ];
then
then
echo -e "\e[43mUser requested to rebuild and reinstall ubuntu-${ubuntu_codename} stock drivers\e[0m"
else
# Patching kernel for RealSense devices
Expand Down