Skip to content

Commit 086281d

Browse files
committed
Does adding the mkdirP call work?
1 parent c937fa4 commit 086281d

File tree

6 files changed

+23
-4
lines changed

6 files changed

+23
-4
lines changed

.github/actions/package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
"@actions/cache": "^4.0.5",
1515
"@actions/core": "^1.11.1",
1616
"@actions/exec": "^1.1.1",
17+
"@actions/io": "^1.1.3",
1718
"@actions/tool-cache": "^2.0.2",
1819
"lodash": "^4.17.21"
1920
},

.github/actions/src/playwright-cache/index.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
import * as core from '@actions/core';
22
import { exec, getExecOutput } from '@actions/exec';
3+
import * as io from '@actions/io';
34
import * as tc from '@actions/tool-cache';
45

56
interface YarnWhyEntry {
@@ -57,12 +58,13 @@ async function main() {
5758
if (!playwrightDir) {
5859
core.info('playwright directory cache not located, installing');
5960

60-
const exitCode = await exec('yarn', ['workspaces', 'foreach', '-A', '--include', packageName, 'run', 'playwright', 'install', 'chromium', '--with-deps', '--only-shell']);
61+
const exitCode = await exec('yarn', ['workspaces', 'foreach', '-A', '--include', packageName, 'run', 'playwright', 'install', 'chromium', '--with-deps', '--only-shell'], { silent: true });
6162
if (exitCode !== 0) {
6263
core.setFailed('Failed to install playwright');
6364
return;
6465
}
6566

67+
await io.mkdirP('~/.cache/ms-playwright');
6668
playwrightDir = await tc.cacheDir('~/.cache/ms-playwright', 'playwright', version);
6769
}
6870

docs/src/modules/1-getting-started/2-start.md

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,12 +34,13 @@ This may prompt you to download the version of Yarn that this repository uses.
3434
3535
## 4. Install the root package's dependencies
3636

37-
Run the following command to ensure that dependencies like `eslint` get installed correctly:
38-
37+
Run the following command to install the root package.
3938
```sh
4039
yarn workspaces focus @sourceacademy/modules
4140
```
4241

42+
This will enable you to use some of the global scripts like templates.
43+
4344
At this point it is not necessary to run `yarn install` yet to install any other dependencies. Depending on what you are doing, there are different methods for installing dependencies.
4445

4546
## Next Steps

docs/src/modules/2-bundle/3-editing.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,13 @@ To install **only** the dependencies required by the bundle you are modifying, u
1010
yarn workspaces focus @sourceacademy/bundle-[desired bundle]
1111
```
1212

13+
> [!TIP]
14+
> You may require functionalities from the root package, or other packages from this repository.
15+
> It is possible to focus multiple workspaces at once:
16+
> ```sh
17+
> yarn workspaces focus @sourceacademy/bundle-[desired bundle] @sourceacademy/modules
18+
> ```
19+
1320
## Adding Dependencies
1421
1522
Your bundle may need other Javascript packages. To add a dependency to your bundle, run the command below:

docs/src/modules/3-tabs/3-editing.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,13 @@ To install **only** the dependencies required by the tab you are modifying, use
1010
yarn workspaces focus @sourceacademy/Tab-[desired tab]
1111
```
1212

13+
> [!TIP]
14+
> You may require functionalities from the root package, or other packages from this repository.
15+
> It is possible to focus multiple workspaces at once:
16+
> ```sh
17+
> yarn workspaces focus @sourceacademy/Tab-[desired tab] @sourceacademy/modules
18+
> ```
19+
1320
## Adding Dependencies
1421
1522
Your tab may need other Javascript packages. To add a dependency to your tab, run the command below:

yarn.lock

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,7 @@ __metadata:
9494
languageName: node
9595
linkType: hard
9696

97-
"@actions/io@npm:^1.0.1, @actions/io@npm:^1.1.1":
97+
"@actions/io@npm:^1.0.1, @actions/io@npm:^1.1.1, @actions/io@npm:^1.1.3":
9898
version: 1.1.3
9999
resolution: "@actions/io@npm:1.1.3"
100100
checksum: 10c0/5b8751918e5bf0bebd923ba917fb1c0e294401e7ff0037f32c92a4efa4215550df1f6633c63fd4efb2bdaae8711e69b9e36925857db1f38935ff62a5c92ec29e
@@ -3758,6 +3758,7 @@ __metadata:
37583758
"@actions/cache": "npm:^4.0.5"
37593759
"@actions/core": "npm:^1.11.1"
37603760
"@actions/exec": "npm:^1.1.1"
3761+
"@actions/io": "npm:^1.1.3"
37613762
"@actions/tool-cache": "npm:^2.0.2"
37623763
"@sourceacademy/modules-repotools": "workspace:^"
37633764
"@types/node": "npm:^22.15.30"

0 commit comments

Comments
 (0)