From 0c36639f724b6eef81496f852af57fe5275530de Mon Sep 17 00:00:00 2001 From: James Ross Date: Tue, 26 Mar 2024 00:31:15 +0000 Subject: [PATCH] docs: add brief docs about packageManager --- README.md | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/README.md b/README.md index 20a53d4..82ea51f 100644 --- a/README.md +++ b/README.md @@ -268,6 +268,23 @@ The resulting output will look something like this: https://.pages.dev ``` +### Using a different package manager + +By default, this action will detect which package manager to use, based on the presence of a `package-lock.json`, `yarn.lock`, `pnpm-lock.yaml`, or `bun.lockb` file. + +If you need to use a specific package manager for your application, you can set the `packageManager` input to `npm`, `yarn`, `pnpm`, or `bun`. You don't need to set this option unless you want to override the default behavior. + + +```yaml +jobs: + deploy: + steps: + uses: cloudflare/wrangler-action@v3 + with: + apiToken: ${{ secrets.CLOUDFLARE_API_TOKEN }} + packageManager: pnpm +``` + ## Troubleshooting ### "I just started using Workers/Wrangler and I don't know what this is!"