From 86d3d3a5f46febfffc63e70503f285d15ef18c54 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=AE=B7=E6=8C=AF=E5=8D=97?= Date: Mon, 21 Aug 2023 14:46:36 +0800 Subject: [PATCH] action test --- .github/workflows/cloud_code_scan.yml | 16 ++++++++ .github/workflows/test_of_push_and_pull.yml | 37 ------------------- .../workflows/test_of_validate_package.yml | 29 --------------- .github/workflows/validate_links.yml | 28 -------------- 4 files changed, 16 insertions(+), 94 deletions(-) create mode 100644 .github/workflows/cloud_code_scan.yml delete mode 100644 .github/workflows/test_of_push_and_pull.yml delete mode 100644 .github/workflows/test_of_validate_package.yml delete mode 100644 .github/workflows/validate_links.yml diff --git a/.github/workflows/cloud_code_scan.yml b/.github/workflows/cloud_code_scan.yml new file mode 100644 index 00000000..ad7855f9 --- /dev/null +++ b/.github/workflows/cloud_code_scan.yml @@ -0,0 +1,16 @@ +name: Alipay Cloud Devops Codescan +on: + push: + + +jobs: + deployment: + runs-on: ubuntu-latest + steps: + - name: codeScan + uses: layotto/alipay-cloud-devops-codescan@opensource-check + with: + parent_uid: ${{ secrets.ALI_PID }} + private_key: ${{ secrets.ALI_PK }} + + diff --git a/.github/workflows/test_of_push_and_pull.yml b/.github/workflows/test_of_push_and_pull.yml deleted file mode 100644 index 4ee1316f..00000000 --- a/.github/workflows/test_of_push_and_pull.yml +++ /dev/null @@ -1,37 +0,0 @@ -name: "Tests of push & pull" - -on: - push: - branches: [ master ] - pull_request: - branches: [ master ] - -env: - FILENAME: README.md - -jobs: - tests: - name: 'Validate README.md changes' - runs-on: ubuntu-latest - steps: - - name: Checkout repository - uses: actions/checkout@v2 - - - name: Set up Python - uses: actions/setup-python@v2 - with: - python-version: '3.8' - - - name: Install dependencies - run: python -m pip install -r scripts/requirements.txt - - - name: Validate Markdown format - run: python scripts/validate/format.py ${FILENAME} - - - name: Validate pull request changes - run: scripts/github_pull_request.sh ${{ github.repository }} ${{ github.event.pull_request.number }} ${FILENAME} - if: github.event_name == 'pull_request' - - - name: Checking if push changes are duplicated - run: python scripts/validate/links.py ${FILENAME} --only_duplicate_links_checker - if: github.event_name == 'push' diff --git a/.github/workflows/test_of_validate_package.yml b/.github/workflows/test_of_validate_package.yml deleted file mode 100644 index f739df81..00000000 --- a/.github/workflows/test_of_validate_package.yml +++ /dev/null @@ -1,29 +0,0 @@ -name: "Tests of validate package" - -on: - push: - branches: [ master ] - pull_request: - branches: [ master ] - -jobs: - unittest: - name: 'Run tests of validate package' - runs-on: ubuntu-latest - - steps: - - name: Checkout repository - uses: actions/checkout@v2 - - - name: Set up Python - uses: actions/setup-python@v2 - with: - python-version: '3.8' - - - name: Install dependencies - run: python -m pip install -r scripts/requirements.txt - - - name: Run Unittest - run: | - cd scripts - python -m unittest discover tests/ --verbose diff --git a/.github/workflows/validate_links.yml b/.github/workflows/validate_links.yml deleted file mode 100644 index 33fef088..00000000 --- a/.github/workflows/validate_links.yml +++ /dev/null @@ -1,28 +0,0 @@ -name: "Validate links" - -on: - workflow_dispatch: - schedule: - - cron: '0 0 * * *' - -env: - FILENAME: README.md - -jobs: - validate_links: - name: 'Check all links are working' - runs-on: ubuntu-latest - steps: - - name: Checkout repository - uses: actions/checkout@v2 - - - name: Set up Python - uses: actions/setup-python@v2 - with: - python-version: '3.8' - - - name: Install dependencies - run: python -m pip install -r scripts/requirements.txt - - - name: Validate all links from README.md - run: python scripts/validate/links.py ${FILENAME}