diff --git a/.eslintrc.js b/.eslintrc.cjs similarity index 100% rename from .eslintrc.js rename to .eslintrc.cjs diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml deleted file mode 100644 index 01376cff..00000000 --- a/.github/workflows/ci.yml +++ /dev/null @@ -1,35 +0,0 @@ -name: WeChat MiniProgram Demo CI/CD - -on: - pull_request: - types: [closed] - branches: - - master -jobs: - upload: - if: github.event.pull_request.merged == true && github.repository == 'wechat-miniprogram/miniprogram-demo' - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 - with: - fetch-depth: 0 - submodules: 'recursive' - token: ${{ secrets.GITHUB_TOKEN }} - - - name: Clone submodule - run: git submodule status - - - name: Install dependencies - run: npm install - - - name: Run package script - run: npm run init - - - name: Upload MiniProgram - env: - WX_PRIVATE_KEY: ${{ secrets.WX_PRIVATE_KEY }} - run: | - mkdir -p ./build - echo "$WX_PRIVATE_KEY" > ./build/key - chmod +x ./build/ci.js - node ./build/ci.js --skip-key-write diff --git a/.github/workflows/pr-lint-check.yml b/.github/workflows/pr-lint-check.yml new file mode 100644 index 00000000..10c6270c --- /dev/null +++ b/.github/workflows/pr-lint-check.yml @@ -0,0 +1,19 @@ +name: PR Lint Check + +on: + pull_request: + branches: [master] + +jobs: + lint: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - name: Set up Node.js + uses: actions/setup-node@v2 + with: + node-version: '16' + - name: Install dependencies + run: npm install + - name: Run lint + run: npm run lint