1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980 |
- @echo off
- set url=https://mirrors.tuna.tsinghua.edu.cn/git/AOSP/platform/
- set tag=android-11.0.0_r48
- set launcher3Url=%url%packages/apps/Launcher3
- set frameworkUrl=%url%frameworks/
- set frameworksBaseUrl=%frameworkUrl%base/
- set frameworksLibsSystemuiUrl=%frameworkUrl%/libs/systemui/
- set dirs=packages packages\\apps frameworks frameworks\\libs
- (for %%d in (%dirs%) do (
- if exist %%d (
- rd /q /s "%%d"
- echo delete dir %%d
- )
- mkdir "%%d"
- echo create dir %%d
- ))
- ::下载Launcher3
- echo.
- echo.
- echo 下载Launcher3
- set appsDir=packages/apps
- set launcher3Dir=%appsDir%/Launcher3
- @echo on
- git -C %appsDir% clone --filter=blob:none --sparse --depth 1 -b %tag% --single-branch --no-checkout %launcher3Url%
- @echo off
- git -C %launcher3Dir% sparse-checkout init --no-cone
- git -C %launcher3Dir% sparse-checkout set /*
- @echo on
- git -C %launcher3Dir% checkout -b %tag% %tag%
- @echo off
- ::删除.git目录
- rd /q /s "%launcher3Dir%/.git"
- ::下载SystemUI
- echo.
- echo.
- echo 下载SystemUI
- set frameworksDir=frameworks
- set frameworksBaseDir=%frameworksDir%/base
- @echo on
- git -C %frameworksDir% clone --filter=blob:none --sparse --depth 1 -b %tag% --single-branch --no-checkout %frameworksBaseUrl%
- @echo off
- git -C %frameworksBaseDir% sparse-checkout init --no-cone
- git -C %frameworksBaseDir% sparse-checkout set !/*
- git -C %frameworksBaseDir% sparse-checkout add !/packages/*
- git -C %frameworksBaseDir% sparse-checkout add !/packages/SystemUI/*
- git -C %frameworksBaseDir% sparse-checkout add packages/SystemUI/plugin_core/
- git -C %frameworksBaseDir% sparse-checkout add packages/SystemUI/shared/
- @echo on
- git -C %frameworksBaseDir% checkout -b %tag% %tag%
- @echo off
- ::删除.git目录
- rd /q /s "%frameworksBaseDir%/.git"
- ::下载iconloaderlib
- echo.
- echo.
- echo 下载iconloaderlib
- set frameworksLibsDir=frameworks/libs
- set frameworksLibsSystemUiDir=%frameworksLibsDir%/systemui
- @echo on
- git -C %frameworksLibsDir% clone --filter=blob:none --sparse --depth 1 -b %tag% --single-branch --no-checkout %frameworksLibsSystemuiUrl%
- @echo off
- git -C %frameworksLibsSystemUiDir% sparse-checkout init --no-cone
- git -C %frameworksLibsSystemUiDir% sparse-checkout set !/*
- git -C %frameworksLibsSystemUiDir% sparse-checkout add !/*/
- git -C %frameworksLibsSystemUiDir% sparse-checkout add /iconloaderlib/
- @echo on
- git -C %frameworksLibsSystemUiDir% checkout -b %tag% %tag%
- @echo off
- ::删除.git目录
- rd /q /s "%frameworksLibsSystemUiDir%/.git"
- @echo on
- pause
|