Update build-linux.md (#765)

This commit is contained in:
Evan Simkowitz 2024-08-24 15:10:54 -07:00 committed by GitHub
parent f2faa6b735
commit 63526fbe8a
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -34,6 +34,23 @@ You'll now have to move the built `scripthaus` binary to a directory in your pat
sudo cp scripthaus /usr/local/bin
```
You also need a relatively modern nodejs with npm and yarn installed.
Node can be installed from [https://nodejs.org](https://nodejs.org).
We use Yarn Modern to manage our packages. The recommended way to install Yarn Modern is using Corepack, a new utility shipped by NodeJS that lets you manage your package manager versioning as you would any packages.
If you installed NodeJS from the official feed (via the website or using NVM), this should come preinstalled. If you use Homebrew or some other feed, you may need to manually install Corepack using `npm install -g corepack`.
For more information on Corepack, check out [this link](https://yarnpkg.com/corepack).
Once you've verified that you have Corepack installed, run the following script to set up Yarn for the repository:
```sh
corepack enable
yarn install
```
## Install nodejs, npm, and yarn
We use [nvm](https://github.com/nvm-sh/nvm) to install nodejs on Linux (you can use an alternate installer if you wish). You must have a relatively recent version of node in order to build the terminal. Different distributions and shells will require different setup instructions. These instructions work for Ubuntu 22 using bash (will install node v20.8.1):