Add stats script for not sync image (#92)

This commit is contained in:
Shiming Zhang 2022-03-08 15:46:08 +08:00 committed by GitHub
parent ec453caeaa
commit 37d67d44e9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 9 additions and 0 deletions

View File

@ -26,6 +26,9 @@ jobs:
https_proxy: socks5://127.0.0.1:8080
run: |
./hack/diff.sh
- name: Stats the number of not sync images
run: |
./hack/stats-not-sync.sh sync.log
- name: Update badge
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}

View File

@ -27,6 +27,9 @@ jobs:
https_proxy: socks5://127.0.0.1:8080
run: |
./hack/diff.sh
- name: Stats the number of not sync images
run: |
./hack/stats-not-sync.sh sync.log
- name: Update badge
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}

3
hack/stats-not-sync.sh Executable file
View File

@ -0,0 +1,3 @@
#!/usr/bin/env bash
cat $1 | grep NOT-SYNCHRONIZED | awk '{print $3}' | grep ':' | tr ':' ' ' | awk '{print $1}' | uniq -c | sort -nrk 1