diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 482771ce..2206b11e 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -16,33 +16,21 @@ jobs: - uses: actions/setup-node@v3 with: node-version: '18' - - name: Get yarn cache directory path - id: yarn-cache-dir-path - working-directory: app - run: echo "dir=$(yarn config get cacheFolder)" >> $GITHUB_OUTPUT - - name: Cache Yarn Packages - id: yarn-cache - uses: actions/cache@v3 - with: - path: ${{ steps.yarn-cache-dir-path.outputs.dir }} - key: yarn-cache-folder-${{ hashFiles('app/yarn.lock', 'app/.yarnrc.yml') }} - restore-keys: | - yarn-cache-folder- + - uses: oven-sh/setup-bun@v1 - name: Install node dependencies working-directory: app - run: | - yarn + run: bun install - name: Lint working-directory: app run: | - yarn typecheck - yarn lint + bun run typecheck + bun run lint - name: Build working-directory: app env: SENTRY_AUTH_TOKEN: ${{ secrets.SENTRY_AUTH_TOKEN }} run: | - yarn build + bun run build tar cfJ micropad.tar.xz build/* - name: Upload artifact uses: actions/upload-artifact@v3 @@ -59,25 +47,15 @@ jobs: - uses: actions/setup-node@v3 with: node-version: '18' - - name: Get yarn cache directory path - id: yarn-cache-dir-path - working-directory: app - run: echo "dir=$(yarn config get cacheFolder)" >> $GITHUB_OUTPUT - - name: Cache Yarn Packages - id: yarn-cache - uses: actions/cache@v3 - with: - path: ${{ steps.yarn-cache-dir-path.outputs.dir }} - key: yarn-cache-folder-${{ hashFiles('app/yarn.lock', 'app/.yarnrc.yml') }} - restore-keys: | - yarn-cache-folder- + - uses: oven-sh/setup-bun@v1 - uses: actions/download-artifact@v3 with: name: micropad - name: Install node dependencies working-directory: app run: | - yarn + bun install + bun run playwright install - name: Run Micropad in background for testing run: | mkdir micropad @@ -86,8 +64,7 @@ jobs: python3 -m http.server 3000 & - name: Test working-directory: app - run: | - yarn test + run: bun run test deploy: name: Deploy runs-on: ubuntu-latest diff --git a/README.md b/README.md index 4f70ff02..78f09656 100644 --- a/README.md +++ b/README.md @@ -8,7 +8,7 @@ There are a couple [GitHub Project boards](https://github.com/orgs/MicroPad/proj ## Building MicroPad You will need the following: -- [Yarn](https://classic.yarnpkg.com/lang/en/) classic +- [Bun](https://bun.sh/) - [Node.js](https://nodejs.org/en/) - [Python 3](https://www.python.org/) @@ -16,14 +16,14 @@ You will need the following: ```bash git clone https://github.com/MicroPad/MicroPad-Core.git micropad-core cd micropad-core/app -yarn +bun install ``` ### Running a dev server ```bash -yarn start +bun run start ``` ### Building for production ```bash -yarn build +bun run build ``` diff --git a/app/.run/build.run.xml b/app/.run/build.run.xml new file mode 100644 index 00000000..0a4f98f9 --- /dev/null +++ b/app/.run/build.run.xml @@ -0,0 +1,12 @@ + + + + + +