Skip to content

Commit

Permalink
add AppCounts
Browse files Browse the repository at this point in the history
  • Loading branch information
Cp0204 committed Jun 22, 2024
1 parent 44df637 commit 1e8cdd7
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion .github/workflows/create-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,20 +27,26 @@ jobs:
run: |
# Build universal
zip AppStore.zip $(find . -type f \( -wholename "./*.json" -o -wholename "./Apps/*.yml" \))
universal_count=$(find ./Apps/ -name "*.yml" | wc -l)
# Build arm
[ -d "./Apps_arm" ] && cp -rfu ./Apps_arm/* ./Apps/
zip AppStore_arm.zip $(find . -type f -wholename "./*.json" && find . -type f -wholename "./Apps/*.yml" -exec grep -rlPz 'x-casaos:\s*\n\s*architectures:[\n\s\w-]*- arm\s*\n' {} \;)
arm_count=$(find ./Apps/ -name "*.yml" | wc -l)
git checkout -- ./Apps && git clean -df ./Apps
# Build arm64
[ -d "./Apps_arm64" ] && cp -rfu ./Apps_arm64/* ./Apps/
zip AppStore_arm64.zip $(find . -type f -wholename "./*.json" && find . -type f -wholename "./Apps/*.yml" -exec grep -rlPz 'x-casaos:\s*\n\s*architectures:[\n\s\w-]*- arm64\s*\n' {} \;)
arm64_count=$(find ./Apps/ -name "*.yml" | wc -l)
git checkout -- ./Apps && git clean -df ./Apps
# Build amd64
[ -d "./Apps_amd64" ] && cp -rfu ./Apps_amd64/* ./Apps/
zip AppStore_amd64.zip $(find . -type f -wholename "./*.json" && find . -type f -wholename "./Apps/*.yml" -exec grep -rlPz 'x-casaos:\s*\n\s*architectures:[\n\s\w-]*- amd64\s*\n' {} \;)
amd64_count=$(find ./Apps/ -name "*.yml" | wc -l)
echo "::set-output name=app_counts::universal: $universal_count, arm: $arm_count, arm64: $arm64_count, amd64: $amd64_count"
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

Expand All @@ -60,7 +66,7 @@ jobs:
tag_name: new
draft: false
prerelease: false
body: "## What's Changed\n\n${{ steps.get_commit_messages.outputs.commits }}"
body: "## What's Changed\n\n${{ steps.get_commit_messages.outputs.commits }}\n\n📊 **App Counts:**\n${{ steps.create_release.outputs.app_counts }}"
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

Expand Down

0 comments on commit 1e8cdd7

Please sign in to comment.