This repository was archived by the owner on Oct 21, 2024. It is now read-only.
File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -25,6 +25,10 @@ inputs:
2525 workingDirectory :
2626 description : " The working directory in which to run Wrangler"
2727 required : false
28+ wranglerVersion :
29+ description : " The version of Wrangler to use"
30+ required : false
31+ default : 2
2832runs :
2933 using : " node16"
3034 main : " index.js"
Original file line number Diff line number Diff line change @@ -22069,6 +22069,7 @@ try {
2206922069 const gitHubToken = (0, import_core.getInput)("gitHubToken", { required: false });
2207022070 const branch = (0, import_core.getInput)("branch", { required: false });
2207122071 const workingDirectory = (0, import_core.getInput)("workingDirectory", { required: false });
22072+ const wranglerVersion = (0, import_core.getInput)("wranglerVersion", { required: false });
2207222073 const getProject = async () => {
2207322074 const response = await (0, import_undici.fetch)(
2207422075 `https://api.cloudflare.com/client/v4/accounts/${accountId}/pages/projects/${projectName}`,
@@ -22084,7 +22085,7 @@ try {
2208422085 $ export CLOUDFLARE_ACCOUNT_ID="${accountId}"
2208522086 }
2208622087
22087- $$ npx wrangler@2 pages publish "${directory}" --project-name="${projectName}" --branch="${branch}"
22088+ $$ npx wrangler@${wranglerVersion} pages publish "${directory}" --project-name="${projectName}" --branch="${branch}"
2208822089 `;
2208922090 const response = await (0, import_undici.fetch)(
2209022091 `https://api.cloudflare.com/client/v4/accounts/${accountId}/pages/projects/${projectName}/deployments`,
Original file line number Diff line number Diff line change 1616 const gitHubToken = getInput ( "gitHubToken" , { required : false } ) ;
1717 const branch = getInput ( "branch" , { required : false } ) ;
1818 const workingDirectory = getInput ( "workingDirectory" , { required : false } ) ;
19+ const wranglerVersion = getInput ( "wranglerVersion" , { required : false } ) ;
1920
2021 const getProject = async ( ) => {
2122 const response = await fetch (
3435 $ export CLOUDFLARE_ACCOUNT_ID="${ accountId } "
3536 }
3637
37- $$ npx wrangler@2 pages publish "${ directory } " --project-name="${ projectName } " --branch="${ branch } "
38+ $$ npx wrangler@${ wranglerVersion } pages publish "${ directory } " --project-name="${ projectName } " --branch="${ branch } "
3839 ` ;
3940
4041 const response = await fetch (
You can’t perform that action at this time.
0 commit comments