From 6325e6b74b7456917af60ea5cef8e60c2459bc70 Mon Sep 17 00:00:00 2001 From: YuzukiTsuru Date: Tue, 21 Jun 2022 22:34:39 +0800 Subject: [PATCH] add new command --- docs/README.md | 4 ++++ envsetup.sh | 8 ++++++++ 2 files changed, 12 insertions(+) diff --git a/docs/README.md b/docs/README.md index e65d2c04..75ec38b2 100644 --- a/docs/README.md +++ b/docs/README.md @@ -310,6 +310,10 @@ Modify the kernel-related patch or need to restore the original kernel, sync to Modify the uboot-related patch or need to restore the original uboot, sync to original +`sync_update` + +Sometimes when you upgrade Buildroot YuzukiSBC, you will find that the compilation does not pass, please use this command to delete the old files + # Appendix ## board file trees and file path definition diff --git a/envsetup.sh b/envsetup.sh index 3d49d5a3..702bf3c5 100644 --- a/envsetup.sh +++ b/envsetup.sh @@ -37,6 +37,12 @@ then export PATH="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/usr/lib/wsl/lib" fi +UpdateInfo(){ + echo "************************************************************" + echo "* Update done! You may need to run sync_update after lunch.*" + echo "************************************************************" +} + FetchUpdate(){ git fetch origin master:tmp if [ $(git diff tmp | grep -c "-") -gt 1 ]; @@ -46,6 +52,7 @@ FetchUpdate(){ [yY][eE][sS]|[yY]) echo "Now try to merge upstream..." git merge tmp + UpdateInfo ;; [nN][oO]|[nN]) @@ -108,6 +115,7 @@ alias rebuild_uboot="make uboot-rebuild -j8 && make" alias wsl_path="export PATH=\"/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/usr/lib/wsl/lib\"" alias sync_kernel="rm -rf output/build/linux* && rm -rf output/build/.linux* && make" alias sync_uboot="rm -rf output/build/uboot* && make" +alias sync_update="rm -rf output/build/linux* && rm -rf output/build/.linux* && rm -rf output/build/uboot* && rm -rf dl/uboot* && rm -rf dl/linux*" alias mm="make" alias m="make"