Semantic Diff

#9240 Run the website's Yarn outside the compiler checkout when publishing

1 commit

89d5411427cf4cdea1a258efaf6670dda4a7b80d..pr-9240

36050db71 · tsnobip + Claude · Nov 05, 2026, 18:23 UTC

Run the website's Yarn outside the compiler checkout when publishing

The publish job checks out rescript-lang.org inside this checkout. Yarn reads every .yarnrc.yml from its working directory up to the root, so the website's Yarn 4.13.0 also read ours, which since #8890 sets approvedGitRepositories, a setting 4.13.0 doesn't know. It stopped with a usage error in "Use Node.js for website", so 13.0.0-alpha.7 was published without its API docs and website playground update.

The job now moves the website checkout to $RUNNER_TEMP and links it back. Yarn starts in the directory the link points to, so it reads only the website's .yarnrc.yml, and the later steps keep their paths.

Review

  • Does pushing the API docs still authenticate? The deploy key is the core.sshCommand in the website's .git/config, which moves with it, and names the key by its absolute path in $RUNNER_TEMP. Only the HTTPS token is included by gitdir path, and the website's remote uses SSH.
  • How was this tested? Locally, with this repository's .yarnrc.yml and the website's Yarn 4.13.0 nested as in the job: before the step, yarn config get cacheFolder fails with the CI error; after it, the command succeeds both from a shell cd through the link and from a spawn with the link as its cwd, which is how setup-node runs it.