From fdc7489a9bc35af82b0c806533160618e6b1749a Mon Sep 17 00:00:00 2001 From: HalfLife Date: Fri, 24 Sep 2021 20:37:43 +0800 Subject: [PATCH] update --- .github/scripts/tg_bot.py | 2 +- .github/workflows/test.yml | 9 ++++++--- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/.github/scripts/tg_bot.py b/.github/scripts/tg_bot.py index d318f2eeb..88a3a8bb5 100644 --- a/.github/scripts/tg_bot.py +++ b/.github/scripts/tg_bot.py @@ -7,7 +7,7 @@ def upload_file(tb, chat_id, file_dir): # 上传文件夹内的文件 def upload_folder(tb, chat_id, folder_dir): - file_list = os.listdir(folder_dir) + file_list = sorted(os.listdir(folder_dir)) for file in file_list: path = os.path.join(folder_dir, file) if os.path.isfile(path): diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 09bca5a60..3f6441b98 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -66,7 +66,6 @@ jobs: sed '$a\RELEASE_STORE_PASSWORD=gedoor_legado' $GITHUB_WORKSPACE/gradle.properties -i sed '$a\RELEASE_KEY_PASSWORD=gedoor_legado' $GITHUB_WORKSPACE/gradle.properties -i - name: Build With Gradle - continue-on-error: true run: | if [ ${{ env.type }} == 'release' ]; then typeName="原包名" @@ -79,7 +78,7 @@ jobs: sed "/def version/c def version = \"${{ env.VERSION }}\"" $GITHUB_WORKSPACE/app/build.gradle -i echo "开始${{ env.product }}$typeName构建" chmod +x gradlew - ./gradlew assemble${{ env.product }}release --build-cache --parallel + ./gradlew assemble${{ env.product }}release --build-cache --parallel --daemon --warning-mode all echo "修改文件名" mkdir -p ${{ github.workspace }}/apk/ for file in `ls ${{ github.workspace }}/app/build/outputs/apk/*/*/*.apk`; do @@ -150,7 +149,11 @@ jobs: with: path: apk/ - working-directory: apk/ - run: mv */*.apk . ;rm -rf */ + run: | + for file in `ls */*.apk`; do + mv "$file" "$(echo "$file"|sed -e 's#.*\/##g' -e "s/_/ /g" -e 's/legado/阅读/')" + done + rm -rf */ - name: Post to channel run: | pip install pyTelegramBotAPI