|
6 | 6 | jobs: |
7 | 7 | base-test: |
8 | 8 | runs-on: ubuntu-latest |
9 | | - outputs: |
10 | | - points: ${{ steps.end.outputs.points}} |
| 9 | + # outputs: |
| 10 | + # points: ${{ steps.end.outputs.points}} |
11 | 11 | container: |
12 | 12 | image: duskmoon/dev-env:ucore-ci |
13 | 13 | steps: |
14 | 14 | - uses: actions/checkout@v3 |
15 | | - - run: git clone https://github.com/LearningOS/uCore-Tutorial-Checker-2023S.git ucore-tutorial-ci |
16 | | - - run: git clone https://github.com/LearningOS/uCore-Tutorial-Test-2023S.git ucore-tutorial-ci/workplace/user |
| 15 | + - run: git clone https://github.com/LearningOS/uCore-Tutorial-Checker-2023A.git ucore-tutorial-ci |
| 16 | + - run: git clone https://github.com/LearningOS/uCore-Tutorial-Test-2023A.git ucore-tutorial-ci/workplace/user |
17 | 17 | - name: run test |
18 | 18 | id: tester |
19 | | - run: cd ucore-tutorial-ci && make test passwd=${{ secrets.BASE_TEST_TOKEN }} CHAPTER=`echo ${GITHUB_REF##*/} | grep -oP 'ch\K[0-9]'` > ../output.txt && cat ../output.txt |
20 | | - - name: end |
21 | | - id: end |
22 | | - run: cat output.txt | grep "Test passed" | grep -oP "\d{1,}/\d{1,}" | xargs -i echo "points={}" >> $GITHUB_OUTPUT |
23 | | - deploy: |
24 | | - if: github.repository != 'LearningOS/uCore-Tutorial-Code-2023S' |
25 | | - name: Deploy to pages |
26 | | - needs: base-test |
27 | | - runs-on: ubuntu-latest |
28 | | - steps: |
29 | | - - uses: actions/checkout@v3 |
30 | | - continue-on-error: true |
31 | | - with: |
32 | | - ref: 'gh-pages' |
33 | | - - name: Save Log File |
34 | | - uses: yfblock/multi-rank-log@main |
35 | | - with: |
36 | | - points: ${{ needs.base-test.outputs.points }} |
37 | | - - name: GitHub Pages |
38 | | - uses: crazy-max/ghaction-github-pages@v3 |
39 | | - with: |
40 | | - target_branch: gh-pages |
41 | | - build_dir: ./public |
42 | | - keep_history: true |
43 | | - env: |
44 | | - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |
| 19 | + # run: cd ucore-tutorial-ci && make test passwd=${{ secrets.BASE_TEST_TOKEN }} CHAPTER=`echo ${GITHUB_REF##*/} | grep -oP 'ch\K[0-9]'` | tee ../output.txt |
| 20 | + run: cd ucore-tutorial-ci && make test passwd=${{ secrets.BASE_TEST_TOKEN }} CHAPTER=`echo ${GITHUB_REF##*/} | grep -oP 'ch\K[0-9]'` |
| 21 | + # - name: end |
| 22 | + # run: cat output.txt | grep "Test passed" | grep -oP "\d{1,}/\d{1,}" | xargs -i echo "points={}" >> $GITHUB_OUTPUT |
| 23 | + # deploy: |
| 24 | + # if: github.repository != 'LearningOS/uCore-Tutorial-Code-2023A' |
| 25 | + # name: Deploy to pages |
| 26 | + # needs: base-test |
| 27 | + # runs-on: ubuntu-latest |
| 28 | + # steps: |
| 29 | + # - uses: actions/checkout@v3 |
| 30 | + # continue-on-error: true |
| 31 | + # with: |
| 32 | + # ref: 'gh-pages' |
| 33 | + # - name: Save Log File |
| 34 | + # uses: yfblock/multi-rank-log@main |
| 35 | + # with: |
| 36 | + # points: ${{ needs.base-test.outputs.points }} |
| 37 | + # - name: GitHub Pages |
| 38 | + # uses: crazy-max/ghaction-github-pages@v3 |
| 39 | + # with: |
| 40 | + # target_branch: gh-pages |
| 41 | + # build_dir: ./public |
| 42 | + # keep_history: true |
| 43 | + # env: |
| 44 | + # GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |
0 commit comments