diff --git a/.github/workflows/run.yml b/.github/workflows/run.yml index 04fe729..20ccc06 100644 --- a/.github/workflows/run.yml +++ b/.github/workflows/run.yml @@ -49,41 +49,41 @@ jobs: chmod +x ~/.cargo/bin/os-checker os-checker layout --help - - name: Test get_release_count - run: cargo test -- test_get_release_count --nocapture - + # - name: Test get_release_count + # run: cargo test -- test_get_release_count --nocapture + # # - name: Test os-checker layout --list-targets # run: cargo test -- test_sel4 --nocapture # # - name: Test pkg_targets # run: cargo test -- test_pkg_targets --nocapture - # - name: Install plugin-cargo - # run: cargo install --path . - # - # - name: Run plugin-cargo - # run: | - # os-checker-plugin-cargo os-checker.json - # tree --gitignore -h tmp - # - # - name: Push to database - # env: - # PLUGIN_PATH: plugin/cargo - # run: | - # git config --global user.name "zjp-CN[bot]" - # git config --global user.email "zjp-CN[bot]@users.noreply.github.com" - # - # echo "正在 clone os-checker/database" - # git clone https://x-access-token:${{ env.ACCESS_TOKEN }}@github.com/os-checker/database.git - # echo "成功 clone os-checker/database" - # - # cd database - # git switch ${{ env.DATABASE }} - # - # rm -rf ${{ env.PLUGIN_PATH }} - # mkdir -p ${{ env.PLUGIN_PATH }} - # mv ../tmp ${{ env.PLUGIN_PATH }}/info - # cp ../push.sh ${{ env.PLUGIN_PATH }} - # - # bash ${{ env.PLUGIN_PATH }}/push.sh - # + - name: Install plugin-cargo + run: cargo install --path . + + - name: Run plugin-cargo + run: | + os-checker-plugin-cargo os-checker.json + tree --gitignore -h tmp + + - name: Push to database + env: + PLUGIN_PATH: plugin/cargo + run: | + git config --global user.name "zjp-CN[bot]" + git config --global user.email "zjp-CN[bot]@users.noreply.github.com" + + echo "正在 clone os-checker/database" + git clone https://x-access-token:${{ env.ACCESS_TOKEN }}@github.com/os-checker/database.git + echo "成功 clone os-checker/database" + + cd database + git switch ${{ env.DATABASE }} + + rm -rf ${{ env.PLUGIN_PATH }} + mkdir -p ${{ env.PLUGIN_PATH }} + mv ../tmp ${{ env.PLUGIN_PATH }}/info + cp ../push.sh ${{ env.PLUGIN_PATH }} + + bash ${{ env.PLUGIN_PATH }}/push.sh +