From ac2652023e7bf25c3e9399f0f540cda11a502deb Mon Sep 17 00:00:00 2001 From: Edouard Bozon Date: Thu, 19 Oct 2023 12:04:19 +0200 Subject: [PATCH] ci: add build and lint --- .github/workflows/ci.yml | 50 +++++++++++++++++++++++++++++++++ .github/workflows/user-flow.yml | 24 ---------------- 2 files changed, 50 insertions(+), 24 deletions(-) create mode 100644 .github/workflows/ci.yml delete mode 100644 .github/workflows/user-flow.yml diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml new file mode 100644 index 0000000..a7ffabc --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,50 @@ +name: CI + +on: + push: + branches: [main] + pull_request: + branches: [main] + +jobs: + build-and-lint: + runs-on: ubuntu-latest + strategy: + matrix: + node-version: [18.x] + steps: + - uses: actions/checkout@v3 + - name: use Node.js ${{ matrix.node-version }} + uses: actions/setup-node@v3 + with: + node-version: ${{ matrix.node-version }} + + - name: Install + run: yarn install --frozen-lockfile + + - name: Lint + run: yarn lint + + - name: Lint + run: yarn build + + user-flow: + runs-on: ubuntu-latest + strategy: + matrix: + node-version: [18.x] + steps: + - uses: actions/checkout@v3 + - name: use Node.js ${{ matrix.node-version }} + uses: actions/setup-node@v3 + with: + node-version: ${{ matrix.node-version }} + + - name: Install + run: yarn install --frozen-lockfile + + - name: Executing user-flow CLI + uses: push-based/user-flow-gh-action@v0.2.0 + with: + verbose: 'on' + rcPath: ./projects/todo-mvc/.user-flowrc.json diff --git a/.github/workflows/user-flow.yml b/.github/workflows/user-flow.yml deleted file mode 100644 index 83fac11..0000000 --- a/.github/workflows/user-flow.yml +++ /dev/null @@ -1,24 +0,0 @@ -name: user-flow -on: - pull_request: - branches: - - main -jobs: - user-flow-integrated-in-ci: - runs-on: ubuntu-latest - strategy: - matrix: - node-version: [18.x] - steps: - - uses: actions/checkout@v3 - - name: use Node.js ${{ matrix.node-version }} - uses: actions/setup-node@v3 - with: - node-version: ${{ matrix.node-version }} - - name: install - run: yarn install --frozen-lockfile - - name: Executing user-flow CLI - uses: push-based/user-flow-gh-action@v0.2.0 - with: - verbose: 'on' - rcPath: ./projects/todo-mvc/.user-flowrc.json