diff --git a/.github/workflows/branch-validation.yml b/.github/workflows/branch-validation.yml new file mode 100644 index 0000000..10fd2d3 --- /dev/null +++ b/.github/workflows/branch-validation.yml @@ -0,0 +1,48 @@ +name: ๐Ÿ› ๏ธ Branch Checkup + +on: + push: + branches: [master] + pull_request: + branches: [master] + +permissions: + contents: read + +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true + +jobs: + checkup: + name: ๐Ÿ‘ฎโ€โ™‚๏ธ Lint, Typecheck, Test and Build + runs-on: ubuntu-latest + steps: + - name: ๐Ÿ— Setup Repo + uses: actions/checkout@v7 + + - name: ๐Ÿ— Setup Node + uses: actions/setup-node@v7 + with: + node-version: 24 + cache: yarn + + # `.yarnrc` points `yarn-path` at scripts/bootstrap.js, which forwards to + # yarn whenever arguments are passed and otherwise installs the example + # app and the pods too. Passing the flags keeps it to the library. + - name: ๐Ÿ“ฆ Install Dependencies + run: yarn install --frozen-lockfile + + - name: ๐Ÿงน Lint + run: yarn lint + + - name: ๐Ÿงช Typecheck + run: yarn typescript + + - name: ๐Ÿงช Test + run: yarn test + + # `prepare` runs `bob build`, so the install above already built once. + # Running it again is what fails the job if the build breaks. + - name: ๐Ÿ› ๏ธ Build + run: yarn prepare