Skip to content

Commit

Permalink
[build] Switch packageManager to pnpm
Browse files Browse the repository at this point in the history
  • Loading branch information
spacey-sooty committed Jul 14, 2024
1 parent 321adbb commit 90afd7f
Show file tree
Hide file tree
Showing 6 changed files with 5,079 additions and 7,971 deletions.
8 changes: 6 additions & 2 deletions .github/workflows/choreo.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,10 @@ jobs:
steps:
- uses: actions/checkout@v4

- uses: pnpm/action-setup@v4
with:
version: 9

- name: Install Linux dependencies
if: startsWith(matrix.os, 'ubuntu')
run: |
Expand All @@ -56,7 +60,7 @@ jobs:
wget
- name: Install Node.js dependencies
run: npm install
run: pnpm install
continue-on-error: true

- name: Set up Windows aarch64 Rust compiler
Expand All @@ -71,7 +75,7 @@ jobs:
if: startsWith(matrix.os, 'macOS')

- name: Build package
run: npm run tauri build ${{ matrix.tauri-build-flags }}
run: pnpm run tauri build ${{ matrix.tauri-build-flags }}

- name: Upload bundle (Windows)
if: startsWith(matrix.os, 'windows')
Expand Down
10 changes: 7 additions & 3 deletions .github/workflows/lint-format.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,20 +34,24 @@ jobs:
libwebkit2gtk-4.0-dev \
wget
- uses: pnpm/action-setup@v4
with:
version: 9

- uses: actions/setup-node@v3
with:
node-version: 18.x
cache: "npm"
cache: "pnpm"

- run: npm install [email protected]
- run: pnpm install [email protected]

- uses: actions/setup-python@v5
with:
python-version: 3.12

- run: pip3 install wpiformat==2024.33

- run: npm run fmt
- run: pnpm run fmt

- run: cargo clippy -- -D warnings
working-directory: src-tauri
Expand Down
16 changes: 8 additions & 8 deletions docs/contributing/building-choreo.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,17 +2,17 @@

### Requirements for Windows

- [npm](https://docs.npmjs.com/downloading-and-installing-node-js-and-npm), [Rust](https://www.rust-lang.org/tools/install) ≥ 1.70.0, [CMake](https://cmake.org/download) ≥ 3.21, [Git](https://git-scm.com/)
- [node](https://docs.npmjs.com/downloading-and-installing-node-js-and-npm), [pnpm](https://pnpm.io/installation), [Rust](https://www.rust-lang.org/tools/install) ≥ 1.70.0, [CMake](https://cmake.org/download) ≥ 3.21, [Git](https://git-scm.com/)
- [Visual Studio Community 2022](https://visualstudio.microsoft.com/vs/community/) with C++ programming language selected during installation

### Requirements for macOS

- [npm](https://docs.npmjs.com/downloading-and-installing-node-js-and-npm), [Rust](https://www.rust-lang.org/tools/install) ≥ 1.70.0, [CMake](https://cmake.org/download) ≥ 3.21, [Git](https://git-scm.com/)
- [node](https://docs.npmjs.com/downloading-and-installing-node-js-and-npm), [pnpm](https://pnpm.io/installation), [Rust](https://www.rust-lang.org/tools/install) ≥ 1.70.0, [CMake](https://cmake.org/download) ≥ 3.21, [Git](https://git-scm.com/)
- Xcode ≥ 15.0.1 command-line tools via `xcode-select --install`

### Requirements for Linux

- [npm](https://docs.npmjs.com/downloading-and-installing-node-js-and-npm), [Rust](https://www.rust-lang.org/tools/install) ≥ 1.70.0, [CMake](https://cmake.org/download) ≥ 3.21, [Git](https://git-scm.com/)
- [node](https://docs.npmjs.com/downloading-and-installing-node-js-and-npm), [pnpm](https://pnpm.io/installation), [Rust](https://www.rust-lang.org/tools/install) ≥ 1.70.0, [CMake](https://cmake.org/download) ≥ 3.21, [Git](https://git-scm.com/)
- GCC ≥ 11 via `sudo apt install gcc`
- Tauri dependencies (see [here](https://tauri.app/v1/guides/getting-started/prerequisites/#setting-up-linux)).

Expand All @@ -25,33 +25,33 @@
Install Node.js dependencies.

```console
npm install
pnpm install
```

Build an NSIS `.exe` installer on Windows, `.dmg` bundle on macOS, or `.deb` package on Linux.

```console
npm run tauri build
pnpm run tauri build
```

## Development Server

Install Node.js dependencies.

```console
npm install
pnpm install
```

Start development server (debug).

```console
npm run tauri dev
pnpm run tauri dev
```

Start development server (release).

```console
npm run tauri dev -- --release
pnpm run tauri dev -- --release
```

## macOS Cross Compilation
Expand Down
Loading

0 comments on commit 90afd7f

Please sign in to comment.