Skip to content

Commit

Permalink
Release 1.5.0 (#86)
Browse files Browse the repository at this point in the history
  • Loading branch information
WalshyDev committed May 23, 2023
1 parent 2df29b9 commit f0a1cd5
Show file tree
Hide file tree
Showing 4 changed files with 27 additions and 4 deletions.
23 changes: 23 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,13 @@ GitHub Action for creating Cloudflare Pages deployments, using the new [Direct U
directory: YOUR_ASSET_DIRECTORY
# Optional: Enable this if you want to have GitHub Deployments triggered
gitHubToken: ${{ secrets.GITHUB_TOKEN }}
# Optional: Switch what branch you are publishing to.
# By default this will be the branch which triggered this workflow
branch: main
# Optional: Change the working directory
workingDirectory: my-site
# Optional: Change the Wrangler version, allows you to point to a specific version or a tag such as `beta`
wranglerVersion: '3'
```

1. Replace `YOUR_ACCOUNT_ID`, `YOUR_PROJECT_NAME` and `YOUR_ASSET_DIRECTORY` with the appropriate values to your Pages project.
Expand Down Expand Up @@ -69,6 +76,22 @@ manually by adding the argument `branch: YOUR_BRANCH_NAME`.

By default Wrangler will run in the root package directory. If your app lives in a monorepo and you want to run Wrangler from its directory, add `workingDirectory: YOUR_PACKAGE_DIRECTORY`.

### Wrangler v3

You can use the newly released [Wrangler v3](https://blog.cloudflare.com/wrangler3/) with the `wranglerVersion` property.

```yaml
- name: Publish to Cloudflare Pages
uses: cloudflare/pages-action@v1
with:
apiToken: ${{ secrets.CLOUDFLARE_API_TOKEN }}
accountId: YOUR_ACCOUNT_ID
projectName: YOUR_PROJECT_NAME
directory: YOUR_ASSET_DIRECTORY
# Enable Wrangler v3
wranglerVersion: '3'
```

## Outputs

| Name | Description |
Expand Down
2 changes: 1 addition & 1 deletion action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ inputs:
wranglerVersion:
description: "The version of Wrangler to use"
required: false
default: 2
default: "2"
runs:
using: "node16"
main: "index.js"
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "pages-action",
"version": "1.3.0",
"version": "1.5.0",
"description": "Publish to Cloudflare Pages",
"main": "index.js",
"scripts": {
Expand Down

0 comments on commit f0a1cd5

Please sign in to comment.