From e2ffd5a348a040cfb2abc840499ef571097572b6 Mon Sep 17 00:00:00 2001 From: Mike McCready <66998419+MikeMcC399@users.noreply.github.com> Date: Mon, 18 Nov 2024 16:22:28 +0100 Subject: [PATCH] docs: add install-command lock file prerequisite (#1310) --- README.md | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 25d885755..c02163a19 100644 --- a/README.md +++ b/README.md @@ -927,7 +927,7 @@ Under Node.js version 18 and later, `wait-on` may fail to recognize that a `loca ### Custom install command -If you want to overwrite the install command +The action installs dependencies based on a package manager lock file using default commands described in the [Installation](#installation) section below. If you want to overwrite the default install command you can use the `install-command` option: ```yml - uses: cypress-io/github-action@v6 @@ -937,6 +937,8 @@ If you want to overwrite the install command See [example-install-command.yml](.github/workflows/example-install-command.yml) workflow file. +If you do not commit a lock file to the repository, you cannot use the action to install dependencies. In this case you must ensure that dependencies are installed before using the action, and you must use the action option setting `install: false`. + ### Command prefix You can prefix the default test command using the `command-prefix` option. This is useful for example when running [Percy](https://docs.percy.io/docs/cypress), which requires the test command to be wrapped with `percy exec --`.