From 8608046dc8f959d57fc4ef6e133975076a3d8202 Mon Sep 17 00:00:00 2001 From: Bruno Paz <184563+brpaz@users.noreply.github.com> Date: Sun, 12 Jun 2022 16:03:45 +0100 Subject: [PATCH] fix --- README.md | 3 ++- index.js | 3 +-- src/index.ts | 4 +--- 3 files changed, 4 insertions(+), 6 deletions(-) diff --git a/README.md b/README.md index 8f1a53a..713ce5a 100644 --- a/README.md +++ b/README.md @@ -32,12 +32,13 @@ GitHub Action for creating Cloudflare Pages deployments, using the new [Direct U projectName: YOUR_PROJECT_NAME directory: YOUR_ASSET_DIRECTORY gitHubToken: ${{ secrets.GITHUB_TOKEN }} + branch: OPTIONAL_BRANCH_NAME_TO_DEPLOY ``` 1. Replace `YOUR_ACCOUNT_ID`, `YOUR_PROJECT_NAME` and `YOUR_ASSET_DIRECTORY` with the appropriate values to your Pages project. ### Get account ID -To find your account ID, log in to the Cloudflare dashboard > select your zone in Account Home > find your account ID in Overview under **API** on the right-side menu. If you have not added a zone, add one by selecting **Add site** . You can purchase a domain from [Cloudflare’s registrar](https://developers.cloudflare.com/registrar/). +To find your account ID, log in to the Cloudflare dashboard > select your zone in Account Home > find your account ID in Overview under **API** on the right-side menu. If you have not added a zone, add one by selecting **Add site** . You can purchase a domain from [Cloudflare’s registrar](https://developers.cloudflare.com/registrar/). If you do not have a zone registered to your account, you can also get your account ID from the `pages.dev` URL. E.g: `https://dash.cloudflare.com//pages` diff --git a/index.js b/index.js index 83e8637..82398dd 100644 --- a/index.js +++ b/index.js @@ -16155,7 +16155,7 @@ try { environmentName, productionEnvironment }) => { - let result = await octokit.rest.repos.createDeploymentStatus({ + await octokit.rest.repos.createDeploymentStatus({ owner: import_github.context.repo.owner, repo: import_github.context.repo.repo, deployment_id: id, @@ -16166,7 +16166,6 @@ try { description: "Cloudflare Pages", state: "success" }); - console.log(result); }; (async () => { const gitHubDeployment = await createGitHubDeployment(); diff --git a/src/index.ts b/src/index.ts index 7ab720e..2beb0f9 100644 --- a/src/index.ts +++ b/src/index.ts @@ -109,7 +109,7 @@ try { environmentName: string; productionEnvironment: boolean; }) => { - let result = await octokit.rest.repos.createDeploymentStatus({ + await octokit.rest.repos.createDeploymentStatus({ owner: context.repo.owner, repo: context.repo.repo, deployment_id: id, @@ -121,8 +121,6 @@ try { description: "Cloudflare Pages", state: "success", }); - - console.log(result); }; (async () => {