From d40634c51e0023e038b284a2039ec2937461b566 Mon Sep 17 00:00:00 2001 From: James Ives Date: Sat, 6 Jun 2020 18:41:15 +0000 Subject: [PATCH 01/14] =?UTF-8?q?Release=203.5.5=20=F0=9F=93=A3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index b8740536..821fab3f 100644 --- a/package.json +++ b/package.json @@ -2,7 +2,7 @@ "name": "@jamesives/github-pages-deploy-action", "description": "GitHub action for building a project and deploying it to GitHub pages.", "author": "James Ives (https://jamesiv.es)", - "version": "3.5.4", + "version": "3.5.5", "license": "MIT", "main": "lib/lib.js", "types": "lib/lib.d.ts", From 613169d65c4f2f8e087f487d6c4dae2dca99f0db Mon Sep 17 00:00:00 2001 From: "dependabot-preview[bot]" <27856297+dependabot-preview[bot]@users.noreply.github.com> Date: Mon, 8 Jun 2020 13:28:28 -0400 Subject: [PATCH 02/14] Bump eslint from 7.1.0 to 7.2.0 (#325) Bumps [eslint](https://github.com/eslint/eslint) from 7.1.0 to 7.2.0. - [Release notes](https://github.com/eslint/eslint/releases) - [Changelog](https://github.com/eslint/eslint/blob/master/CHANGELOG.md) - [Commits](https://github.com/eslint/eslint/compare/v7.1.0...v7.2.0) Signed-off-by: dependabot-preview[bot] Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com> --- package.json | 2 +- yarn.lock | 38 +++++++++++++++++++++----------------- 2 files changed, 22 insertions(+), 18 deletions(-) diff --git a/package.json b/package.json index 821fab3f..f7f9caf4 100644 --- a/package.json +++ b/package.json @@ -41,7 +41,7 @@ "devDependencies": { "@types/jest": "25.2.3", "@types/node": "14.0.11", - "eslint": "7.1.0", + "eslint": "7.2.0", "eslint-plugin-github": "3.4.1", "eslint-plugin-jest": "23.13.2", "eslint-plugin-prettier": "^3.1.2", diff --git a/yarn.lock b/yarn.lock index 8b3f2b07..0b98efce 100644 --- a/yarn.lock +++ b/yarn.lock @@ -896,6 +896,10 @@ acorn@^7.1.1: version "7.1.1" resolved "https://registry.yarnpkg.com/acorn/-/acorn-7.1.1.tgz#e35668de0b402f359de515c5482a1ab9f89a69bf" +acorn@^7.2.0: + version "7.2.0" + resolved "https://registry.yarnpkg.com/acorn/-/acorn-7.2.0.tgz#17ea7e40d7c8640ff54a694c889c26f31704effe" + ajv@^6.10.0, ajv@^6.10.2, ajv@^6.5.5: version "6.12.0" resolved "https://registry.yarnpkg.com/ajv/-/ajv-6.12.0.tgz#06d60b96d87b8454a5adaba86e7854da629db4b7" @@ -1794,9 +1798,9 @@ eslint-rule-documentation@>=1.0.0: version "1.0.23" resolved "https://registry.yarnpkg.com/eslint-rule-documentation/-/eslint-rule-documentation-1.0.23.tgz#4e0886145597a78d24524ec7e0cf18c6fedc23a8" -eslint-scope@^5.0.0: - version "5.0.0" - resolved "https://registry.yarnpkg.com/eslint-scope/-/eslint-scope-5.0.0.tgz#e87c8887c73e8d1ec84f1ca591645c358bfc8fb9" +eslint-scope@^5.0.0, eslint-scope@^5.1.0: + version "5.1.0" + resolved "https://registry.yarnpkg.com/eslint-scope/-/eslint-scope-5.1.0.tgz#d0f971dfe59c69e0cada684b23d49dbf82600ce5" dependencies: esrecurse "^4.1.0" estraverse "^4.1.1" @@ -1813,13 +1817,13 @@ eslint-utils@^2.0.0: dependencies: eslint-visitor-keys "^1.1.0" -eslint-visitor-keys@^1.0.0, eslint-visitor-keys@^1.1.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/eslint-visitor-keys/-/eslint-visitor-keys-1.1.0.tgz#e2a82cea84ff246ad6fb57f9bde5b46621459ec2" +eslint-visitor-keys@^1.0.0, eslint-visitor-keys@^1.1.0, eslint-visitor-keys@^1.2.0: + version "1.2.0" + resolved "https://registry.yarnpkg.com/eslint-visitor-keys/-/eslint-visitor-keys-1.2.0.tgz#74415ac884874495f78ec2a97349525344c981fa" -eslint@7.1.0: - version "7.1.0" - resolved "https://registry.yarnpkg.com/eslint/-/eslint-7.1.0.tgz#d9a1df25e5b7859b0a3d86bb05f0940ab676a851" +eslint@7.2.0: + version "7.2.0" + resolved "https://registry.yarnpkg.com/eslint/-/eslint-7.2.0.tgz#d41b2e47804b30dbabb093a967fb283d560082e6" dependencies: "@babel/code-frame" "^7.0.0" ajv "^6.10.0" @@ -1827,10 +1831,10 @@ eslint@7.1.0: cross-spawn "^7.0.2" debug "^4.0.1" doctrine "^3.0.0" - eslint-scope "^5.0.0" + eslint-scope "^5.1.0" eslint-utils "^2.0.0" - eslint-visitor-keys "^1.1.0" - espree "^7.0.0" + eslint-visitor-keys "^1.2.0" + espree "^7.1.0" esquery "^1.2.0" esutils "^2.0.2" file-entry-cache "^5.0.1" @@ -1858,13 +1862,13 @@ eslint@7.1.0: text-table "^0.2.0" v8-compile-cache "^2.0.3" -espree@^7.0.0: - version "7.0.0" - resolved "https://registry.yarnpkg.com/espree/-/espree-7.0.0.tgz#8a7a60f218e69f120a842dc24c5a88aa7748a74e" +espree@^7.1.0: + version "7.1.0" + resolved "https://registry.yarnpkg.com/espree/-/espree-7.1.0.tgz#a9c7f18a752056735bf1ba14cb1b70adc3a5ce1c" dependencies: - acorn "^7.1.1" + acorn "^7.2.0" acorn-jsx "^5.2.0" - eslint-visitor-keys "^1.1.0" + eslint-visitor-keys "^1.2.0" esprima@^4.0.0, esprima@^4.0.1: version "4.0.1" From 36051790a82edc52f2c6051d5c8fe2d81b056758 Mon Sep 17 00:00:00 2001 From: "dependabot-preview[bot]" <27856297+dependabot-preview[bot]@users.noreply.github.com> Date: Mon, 15 Jun 2020 09:57:02 -0400 Subject: [PATCH 03/14] Bump @types/node from 14.0.11 to 14.0.13 (#329) Bumps [@types/node](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/node) from 14.0.11 to 14.0.13. - [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases) - [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/node) Signed-off-by: dependabot-preview[bot] Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com> --- package.json | 2 +- yarn.lock | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/package.json b/package.json index f7f9caf4..e36d2b2d 100644 --- a/package.json +++ b/package.json @@ -40,7 +40,7 @@ }, "devDependencies": { "@types/jest": "25.2.3", - "@types/node": "14.0.11", + "@types/node": "14.0.13", "eslint": "7.2.0", "eslint-plugin-github": "3.4.1", "eslint-plugin-jest": "23.13.2", diff --git a/yarn.lock b/yarn.lock index 0b98efce..f00b9f82 100644 --- a/yarn.lock +++ b/yarn.lock @@ -761,9 +761,9 @@ version "7.0.4" resolved "https://registry.yarnpkg.com/@types/json-schema/-/json-schema-7.0.4.tgz#38fd73ddfd9b55abb1e1b2ed578cb55bd7b7d339" -"@types/node@*", "@types/node@14.0.11", "@types/node@>= 8": - version "14.0.11" - resolved "https://registry.yarnpkg.com/@types/node/-/node-14.0.11.tgz#61d4886e2424da73b7b25547f59fdcb534c165a3" +"@types/node@*", "@types/node@14.0.13", "@types/node@>= 8": + version "14.0.13" + resolved "https://registry.yarnpkg.com/@types/node/-/node-14.0.13.tgz#ee1128e881b874c371374c1f72201893616417c9" "@types/normalize-package-data@^2.4.0": version "2.4.0" From 2ce22fae3a445985deeaeedb29c9f1d99e533e4b Mon Sep 17 00:00:00 2001 From: "dependabot-preview[bot]" <27856297+dependabot-preview[bot]@users.noreply.github.com> Date: Mon, 15 Jun 2020 10:25:31 -0400 Subject: [PATCH 04/14] Bump @types/jest from 25.2.3 to 26.0.0 (#328) Bumps [@types/jest](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/jest) from 25.2.3 to 26.0.0. - [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases) - [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/jest) Signed-off-by: dependabot-preview[bot] Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com> --- package.json | 2 +- yarn.lock | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/package.json b/package.json index e36d2b2d..2cc95a88 100644 --- a/package.json +++ b/package.json @@ -39,7 +39,7 @@ "@actions/io": "1.0.2" }, "devDependencies": { - "@types/jest": "25.2.3", + "@types/jest": "26.0.0", "@types/node": "14.0.13", "eslint": "7.2.0", "eslint-plugin-github": "3.4.1", diff --git a/yarn.lock b/yarn.lock index f00b9f82..4a22706a 100644 --- a/yarn.lock +++ b/yarn.lock @@ -750,9 +750,9 @@ "@types/istanbul-lib-coverage" "*" "@types/istanbul-lib-report" "*" -"@types/jest@25.2.3": - version "25.2.3" - resolved "https://registry.yarnpkg.com/@types/jest/-/jest-25.2.3.tgz#33d27e4c4716caae4eced355097a47ad363fdcaf" +"@types/jest@26.0.0": + version "26.0.0" + resolved "https://registry.yarnpkg.com/@types/jest/-/jest-26.0.0.tgz#a6d7573dffa9c68cbbdf38f2e0de26f159e11134" dependencies: jest-diff "^25.2.1" pretty-format "^25.2.1" From dce3848163418bd45637bc6a4fbac571f1db0ab5 Mon Sep 17 00:00:00 2001 From: James Ives Date: Mon, 15 Jun 2020 10:26:44 -0400 Subject: [PATCH 05/14] Makes check (#332) --- src/git.ts | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) diff --git a/src/git.ts b/src/git.ts index fde9eee2..4dbc3df9 100644 --- a/src/git.ts +++ b/src/git.ts @@ -19,11 +19,16 @@ export async function init(action: ActionInterface): Promise { await execute(`git init`, action.workspace) await execute(`git config user.name "${action.name}"`, action.workspace) await execute(`git config user.email "${action.email}"`, action.workspace) - await execute(`git remote rm origin`, action.workspace) - await execute( - `git remote add origin ${action.repositoryPath}`, - action.workspace - ) + + try { + await execute(`git remote rm origin`, action.workspace) + } finally { + await execute( + `git remote add origin ${action.repositoryPath}`, + action.workspace + ) + } + await execute(`git fetch --no-recurse-submodules`, action.workspace) info('Git configured… 🔧') From 3c226bcd5e95f19923be2978c0adcf4d5aa4db56 Mon Sep 17 00:00:00 2001 From: James Ives Date: Tue, 16 Jun 2020 06:16:48 -0400 Subject: [PATCH 06/14] Revert "Makes check (#332)" (#334) This reverts commit dce3848163418bd45637bc6a4fbac571f1db0ab5. --- src/git.ts | 15 +++++---------- 1 file changed, 5 insertions(+), 10 deletions(-) diff --git a/src/git.ts b/src/git.ts index 4dbc3df9..fde9eee2 100644 --- a/src/git.ts +++ b/src/git.ts @@ -19,16 +19,11 @@ export async function init(action: ActionInterface): Promise { await execute(`git init`, action.workspace) await execute(`git config user.name "${action.name}"`, action.workspace) await execute(`git config user.email "${action.email}"`, action.workspace) - - try { - await execute(`git remote rm origin`, action.workspace) - } finally { - await execute( - `git remote add origin ${action.repositoryPath}`, - action.workspace - ) - } - + await execute(`git remote rm origin`, action.workspace) + await execute( + `git remote add origin ${action.repositoryPath}`, + action.workspace + ) await execute(`git fetch --no-recurse-submodules`, action.workspace) info('Git configured… 🔧') From 7e75ecc4f19bd3212f04bf7e025e633ab05fc1bd Mon Sep 17 00:00:00 2001 From: "dependabot-preview[bot]" <27856297+dependabot-preview[bot]@users.noreply.github.com> Date: Tue, 16 Jun 2020 10:04:35 -0400 Subject: [PATCH 07/14] Bump eslint-plugin-prettier from 3.1.3 to 3.1.4 (#333) Bumps [eslint-plugin-prettier](https://github.com/prettier/eslint-plugin-prettier) from 3.1.3 to 3.1.4. - [Release notes](https://github.com/prettier/eslint-plugin-prettier/releases) - [Changelog](https://github.com/prettier/eslint-plugin-prettier/blob/master/CHANGELOG.md) - [Commits](https://github.com/prettier/eslint-plugin-prettier/compare/v3.1.3...v3.1.4) Signed-off-by: dependabot-preview[bot] Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com> --- yarn.lock | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/yarn.lock b/yarn.lock index 4a22706a..fd22ddd8 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1766,8 +1766,8 @@ eslint-plugin-jsx-a11y@>=6.0.0: jsx-ast-utils "^2.2.1" eslint-plugin-prettier@>=2.6.0, eslint-plugin-prettier@^3.1.2: - version "3.1.3" - resolved "https://registry.yarnpkg.com/eslint-plugin-prettier/-/eslint-plugin-prettier-3.1.3.tgz#ae116a0fc0e598fdae48743a4430903de5b4e6ca" + version "3.1.4" + resolved "https://registry.yarnpkg.com/eslint-plugin-prettier/-/eslint-plugin-prettier-3.1.4.tgz#168ab43154e2ea57db992a2cd097c828171f75c2" dependencies: prettier-linter-helpers "^1.0.0" From 95cdadb8d248e6e478616c32bfbe05c52e563ce5 Mon Sep 17 00:00:00 2001 From: James Ives Date: Wed, 17 Jun 2020 09:06:27 -0400 Subject: [PATCH 08/14] Update README.md --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 366f3716..2f2b85ed 100644 --- a/README.md +++ b/README.md @@ -140,7 +140,7 @@ In addition to the deployment options you must also configure the following. | ------------------ | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------ | -------- | | `GIT_CONFIG_NAME` | Allows you to customize the name that is attached to the git config which is used when pushing the deployment commits. If this is not included it will use the name in the GitHub context, followed by the name of the action. | `with` | **No** | | `GIT_CONFIG_EMAIL` | Allows you to customize the email that is attached to the git config which is used when pushing the deployment commits. If this is not included it will use the email in the GitHub context, followed by a generic noreply GitHub email. | `with` | **No** | -| `REPOSITORY_NAME` | Allows you to specify a different repository path so long as you have permissions to push to it. This should be formatted like so: `JamesIves/github-pages-deploy-action`. | `with` | **No** | +| `REPOSITORY_NAME` | Allows you to specify a different repository path so long as you have permissions to push to it. This should be formatted like so: `JamesIves/github-pages-deploy-action`. You'll need to use an `ACCESS_TOKEN` for this configuration option to work properly. | `with` | **No** | | `TARGET_FOLDER` | If you'd like to push the contents of the deployment folder into a specific directory on the deployment branch you can specify it here. | `with` | **No** | | `BASE_BRANCH` | The base branch of your repository which you'd like to checkout prior to deploying. This defaults to the current commit [SHA](http://en.wikipedia.org/wiki/SHA-1) that triggered the build followed by `master` if it doesn't exist. This is useful for making deployments from another branch, and also may be necessary when using a scheduled job. | `with` | **No** | | `COMMIT_MESSAGE` | If you need to customize the commit message for an integration you can do so. | `with` | **No** | From f2485efda8b712485c15112c162efc106948fd88 Mon Sep 17 00:00:00 2001 From: "dependabot-preview[bot]" <27856297+dependabot-preview[bot]@users.noreply.github.com> Date: Thu, 25 Jun 2020 20:05:49 -0400 Subject: [PATCH 09/14] Bump eslint-plugin-jest from 23.13.2 to 23.17.1 (#339) Bumps [eslint-plugin-jest](https://github.com/jest-community/eslint-plugin-jest) from 23.13.2 to 23.17.1. - [Release notes](https://github.com/jest-community/eslint-plugin-jest/releases) - [Changelog](https://github.com/jest-community/eslint-plugin-jest/blob/master/CHANGELOG.md) - [Commits](https://github.com/jest-community/eslint-plugin-jest/compare/v23.13.2...v23.17.1) Signed-off-by: dependabot-preview[bot] Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com> --- package.json | 2 +- yarn.lock | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/package.json b/package.json index 2cc95a88..3bd5eedd 100644 --- a/package.json +++ b/package.json @@ -43,7 +43,7 @@ "@types/node": "14.0.13", "eslint": "7.2.0", "eslint-plugin-github": "3.4.1", - "eslint-plugin-jest": "23.13.2", + "eslint-plugin-jest": "23.17.1", "eslint-plugin-prettier": "^3.1.2", "jest": "25.5.4", "jest-circus": "26.0.1", diff --git a/yarn.lock b/yarn.lock index fd22ddd8..ca247ba5 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1733,9 +1733,9 @@ eslint-plugin-import@>=2.18.2: read-pkg-up "^2.0.0" resolve "^1.12.0" -eslint-plugin-jest@23.13.2: - version "23.13.2" - resolved "https://registry.yarnpkg.com/eslint-plugin-jest/-/eslint-plugin-jest-23.13.2.tgz#7b7993b4e09be708c696b02555083ddefd7e4cc7" +eslint-plugin-jest@23.17.1: + version "23.17.1" + resolved "https://registry.yarnpkg.com/eslint-plugin-jest/-/eslint-plugin-jest-23.17.1.tgz#c0f39ba78e0f33b7ee1ce4ec92b773e39026ea3f" dependencies: "@typescript-eslint/experimental-utils" "^2.5.0" From c8688d5d69fdf0c91fdbcbf454e26b6e12de05c6 Mon Sep 17 00:00:00 2001 From: "dependabot-preview[bot]" <27856297+dependabot-preview[bot]@users.noreply.github.com> Date: Thu, 25 Jun 2020 20:06:01 -0400 Subject: [PATCH 10/14] Bump eslint from 7.2.0 to 7.3.1 (#340) Bumps [eslint](https://github.com/eslint/eslint) from 7.2.0 to 7.3.1. - [Release notes](https://github.com/eslint/eslint/releases) - [Changelog](https://github.com/eslint/eslint/blob/master/CHANGELOG.md) - [Commits](https://github.com/eslint/eslint/compare/v7.2.0...v7.3.1) Signed-off-by: dependabot-preview[bot] Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com> --- package.json | 2 +- yarn.lock | 20 +++++++++++++++----- 2 files changed, 16 insertions(+), 6 deletions(-) diff --git a/package.json b/package.json index 3bd5eedd..9b8dd19d 100644 --- a/package.json +++ b/package.json @@ -41,7 +41,7 @@ "devDependencies": { "@types/jest": "26.0.0", "@types/node": "14.0.13", - "eslint": "7.2.0", + "eslint": "7.3.1", "eslint-plugin-github": "3.4.1", "eslint-plugin-jest": "23.17.1", "eslint-plugin-prettier": "^3.1.2", diff --git a/yarn.lock b/yarn.lock index ca247ba5..7a744e13 100644 --- a/yarn.lock +++ b/yarn.lock @@ -909,6 +909,10 @@ ajv@^6.10.0, ajv@^6.10.2, ajv@^6.5.5: json-schema-traverse "^0.4.1" uri-js "^4.2.2" +ansi-colors@^3.2.1: + version "3.2.4" + resolved "https://registry.yarnpkg.com/ansi-colors/-/ansi-colors-3.2.4.tgz#e3a3da4bfbae6c86a9c285625de124a234026fbf" + ansi-escapes@^4.2.1: version "4.3.0" resolved "https://registry.yarnpkg.com/ansi-escapes/-/ansi-escapes-4.3.0.tgz#a4ce2b33d6b214b7950d8595c212f12ac9cc569d" @@ -1592,6 +1596,12 @@ end-of-stream@^1.1.0: dependencies: once "^1.4.0" +enquirer@^2.3.5: + version "2.3.5" + resolved "https://registry.yarnpkg.com/enquirer/-/enquirer-2.3.5.tgz#3ab2b838df0a9d8ab9e7dff235b0e8712ef92381" + dependencies: + ansi-colors "^3.2.1" + error-ex@^1.2.0, error-ex@^1.3.1: version "1.3.2" resolved "https://registry.yarnpkg.com/error-ex/-/error-ex-1.3.2.tgz#b4ac40648107fdcdcfae242f428bea8a14d4f1bf" @@ -1821,9 +1831,9 @@ eslint-visitor-keys@^1.0.0, eslint-visitor-keys@^1.1.0, eslint-visitor-keys@^1.2 version "1.2.0" resolved "https://registry.yarnpkg.com/eslint-visitor-keys/-/eslint-visitor-keys-1.2.0.tgz#74415ac884874495f78ec2a97349525344c981fa" -eslint@7.2.0: - version "7.2.0" - resolved "https://registry.yarnpkg.com/eslint/-/eslint-7.2.0.tgz#d41b2e47804b30dbabb093a967fb283d560082e6" +eslint@7.3.1: + version "7.3.1" + resolved "https://registry.yarnpkg.com/eslint/-/eslint-7.3.1.tgz#76392bd7e44468d046149ba128d1566c59acbe19" dependencies: "@babel/code-frame" "^7.0.0" ajv "^6.10.0" @@ -1831,6 +1841,7 @@ eslint@7.2.0: cross-spawn "^7.0.2" debug "^4.0.1" doctrine "^3.0.0" + enquirer "^2.3.5" eslint-scope "^5.1.0" eslint-utils "^2.0.0" eslint-visitor-keys "^1.2.0" @@ -1844,7 +1855,6 @@ eslint@7.2.0: ignore "^4.0.6" import-fresh "^3.0.0" imurmurhash "^0.1.4" - inquirer "^7.0.0" is-glob "^4.0.0" js-yaml "^3.13.1" json-stable-stringify-without-jsonify "^1.0.1" @@ -2360,7 +2370,7 @@ inherits@2: version "2.0.4" resolved "https://registry.yarnpkg.com/inherits/-/inherits-2.0.4.tgz#0fa2c64f932917c3433a0ded55363aae37416b7c" -inquirer@>=6.0.0, inquirer@^7.0.0: +inquirer@>=6.0.0: version "7.1.0" resolved "https://registry.yarnpkg.com/inquirer/-/inquirer-7.1.0.tgz#1298a01859883e17c7264b82870ae1034f92dd29" dependencies: From 04e4801dbb0993b960cc20e059bf3cd1883f237d Mon Sep 17 00:00:00 2001 From: "dependabot-preview[bot]" <27856297+dependabot-preview[bot]@users.noreply.github.com> Date: Thu, 25 Jun 2020 20:06:09 -0400 Subject: [PATCH 11/14] Bump jest-circus from 26.0.1 to 26.1.0 (#341) Bumps [jest-circus](https://github.com/facebook/jest/tree/HEAD/packages/jest-circus) from 26.0.1 to 26.1.0. - [Release notes](https://github.com/facebook/jest/releases) - [Changelog](https://github.com/facebook/jest/blob/master/CHANGELOG.md) - [Commits](https://github.com/facebook/jest/commits/v26.1.0/packages/jest-circus) Signed-off-by: dependabot-preview[bot] Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com> --- package.json | 2 +- yarn.lock | 473 ++++++++++++++++++++++++++------------------------- 2 files changed, 243 insertions(+), 232 deletions(-) diff --git a/package.json b/package.json index 9b8dd19d..a6182714 100644 --- a/package.json +++ b/package.json @@ -46,7 +46,7 @@ "eslint-plugin-jest": "23.17.1", "eslint-plugin-prettier": "^3.1.2", "jest": "25.5.4", - "jest-circus": "26.0.1", + "jest-circus": "26.1.0", "prettier": "2.0.5", "ts-jest": "25.5.1", "typescript": "3.9.5" diff --git a/yarn.lock b/yarn.lock index 7a744e13..ff0bf25e 100644 --- a/yarn.lock +++ b/yarn.lock @@ -331,14 +331,14 @@ jest-util "^25.5.0" slash "^3.0.0" -"@jest/console@^26.0.1": - version "26.0.1" - resolved "https://registry.yarnpkg.com/@jest/console/-/console-26.0.1.tgz#62b3b2fa8990f3cbffbef695c42ae9ddbc8f4b39" +"@jest/console@^26.1.0": + version "26.1.0" + resolved "https://registry.yarnpkg.com/@jest/console/-/console-26.1.0.tgz#f67c89e4f4d04dbcf7b052aed5ab9c74f915b954" dependencies: - "@jest/types" "^26.0.1" + "@jest/types" "^26.1.0" chalk "^4.0.0" - jest-message-util "^26.0.1" - jest-util "^26.0.1" + jest-message-util "^26.1.0" + jest-util "^26.1.0" slash "^3.0.0" "@jest/core@^25.5.4": @@ -382,13 +382,13 @@ "@jest/types" "^25.5.0" jest-mock "^25.5.0" -"@jest/environment@^26.0.1": - version "26.0.1" - resolved "https://registry.yarnpkg.com/@jest/environment/-/environment-26.0.1.tgz#82f519bba71959be9b483675ee89de8c8f72a5c8" +"@jest/environment@^26.1.0": + version "26.1.0" + resolved "https://registry.yarnpkg.com/@jest/environment/-/environment-26.1.0.tgz#378853bcdd1c2443b4555ab908cfbabb851e96da" dependencies: - "@jest/fake-timers" "^26.0.1" - "@jest/types" "^26.0.1" - jest-mock "^26.0.1" + "@jest/fake-timers" "^26.1.0" + "@jest/types" "^26.1.0" + jest-mock "^26.1.0" "@jest/fake-timers@^25.5.0": version "25.5.0" @@ -400,15 +400,15 @@ jest-util "^25.5.0" lolex "^5.0.0" -"@jest/fake-timers@^26.0.1": - version "26.0.1" - resolved "https://registry.yarnpkg.com/@jest/fake-timers/-/fake-timers-26.0.1.tgz#f7aeff13b9f387e9d0cac9a8de3bba538d19d796" +"@jest/fake-timers@^26.1.0": + version "26.1.0" + resolved "https://registry.yarnpkg.com/@jest/fake-timers/-/fake-timers-26.1.0.tgz#9a76b7a94c351cdbc0ad53e5a748789f819a65fe" dependencies: - "@jest/types" "^26.0.1" + "@jest/types" "^26.1.0" "@sinonjs/fake-timers" "^6.0.1" - jest-message-util "^26.0.1" - jest-mock "^26.0.1" - jest-util "^26.0.1" + jest-message-util "^26.1.0" + jest-mock "^26.1.0" + jest-util "^26.1.0" "@jest/globals@^25.5.2": version "25.5.2" @@ -418,13 +418,13 @@ "@jest/types" "^25.5.0" expect "^25.5.0" -"@jest/globals@^26.0.1": - version "26.0.1" - resolved "https://registry.yarnpkg.com/@jest/globals/-/globals-26.0.1.tgz#3f67b508a7ce62b6e6efc536f3d18ec9deb19a9c" +"@jest/globals@^26.1.0": + version "26.1.0" + resolved "https://registry.yarnpkg.com/@jest/globals/-/globals-26.1.0.tgz#6cc5d7cbb79b76b120f2403d7d755693cf063ab1" dependencies: - "@jest/environment" "^26.0.1" - "@jest/types" "^26.0.1" - expect "^26.0.1" + "@jest/environment" "^26.1.0" + "@jest/types" "^26.1.0" + expect "^26.1.0" "@jest/reporters@^25.5.1": version "25.5.1" @@ -465,9 +465,9 @@ graceful-fs "^4.2.4" source-map "^0.6.0" -"@jest/source-map@^26.0.0": - version "26.0.0" - resolved "https://registry.yarnpkg.com/@jest/source-map/-/source-map-26.0.0.tgz#fd7706484a7d3faf7792ae29783933bbf48a4749" +"@jest/source-map@^26.1.0": + version "26.1.0" + resolved "https://registry.yarnpkg.com/@jest/source-map/-/source-map-26.1.0.tgz#a6a020d00e7d9478f4b690167c5e8b77e63adb26" dependencies: callsites "^3.0.0" graceful-fs "^4.2.4" @@ -482,12 +482,12 @@ "@types/istanbul-lib-coverage" "^2.0.0" collect-v8-coverage "^1.0.0" -"@jest/test-result@^26.0.1": - version "26.0.1" - resolved "https://registry.yarnpkg.com/@jest/test-result/-/test-result-26.0.1.tgz#1ffdc1ba4bc289919e54b9414b74c9c2f7b2b718" +"@jest/test-result@^26.1.0": + version "26.1.0" + resolved "https://registry.yarnpkg.com/@jest/test-result/-/test-result-26.1.0.tgz#a93fa15b21ad3c7ceb21c2b4c35be2e407d8e971" dependencies: - "@jest/console" "^26.0.1" - "@jest/types" "^26.0.1" + "@jest/console" "^26.1.0" + "@jest/types" "^26.1.0" "@types/istanbul-lib-coverage" "^2.0.0" collect-v8-coverage "^1.0.0" @@ -501,15 +501,15 @@ jest-runner "^25.5.4" jest-runtime "^25.5.4" -"@jest/test-sequencer@^26.0.1": - version "26.0.1" - resolved "https://registry.yarnpkg.com/@jest/test-sequencer/-/test-sequencer-26.0.1.tgz#b0563424728f3fe9e75d1442b9ae4c11da73f090" +"@jest/test-sequencer@^26.1.0": + version "26.1.0" + resolved "https://registry.yarnpkg.com/@jest/test-sequencer/-/test-sequencer-26.1.0.tgz#41a6fc8b850c3f33f48288ea9ea517c047e7f14e" dependencies: - "@jest/test-result" "^26.0.1" + "@jest/test-result" "^26.1.0" graceful-fs "^4.2.4" - jest-haste-map "^26.0.1" - jest-runner "^26.0.1" - jest-runtime "^26.0.1" + jest-haste-map "^26.1.0" + jest-runner "^26.1.0" + jest-runtime "^26.1.0" "@jest/transform@^25.5.1": version "25.5.1" @@ -532,20 +532,20 @@ source-map "^0.6.1" write-file-atomic "^3.0.0" -"@jest/transform@^26.0.1": - version "26.0.1" - resolved "https://registry.yarnpkg.com/@jest/transform/-/transform-26.0.1.tgz#0e3ecbb34a11cd4b2080ed0a9c4856cf0ceb0639" +"@jest/transform@^26.1.0": + version "26.1.0" + resolved "https://registry.yarnpkg.com/@jest/transform/-/transform-26.1.0.tgz#697f48898c2a2787c9b4cb71d09d7e617464e509" dependencies: "@babel/core" "^7.1.0" - "@jest/types" "^26.0.1" + "@jest/types" "^26.1.0" babel-plugin-istanbul "^6.0.0" chalk "^4.0.0" convert-source-map "^1.4.0" fast-json-stable-stringify "^2.0.0" graceful-fs "^4.2.4" - jest-haste-map "^26.0.1" + jest-haste-map "^26.1.0" jest-regex-util "^26.0.0" - jest-util "^26.0.1" + jest-util "^26.1.0" micromatch "^4.0.2" pirates "^4.0.1" slash "^3.0.0" @@ -561,9 +561,9 @@ "@types/yargs" "^15.0.0" chalk "^3.0.0" -"@jest/types@^26.0.1": - version "26.0.1" - resolved "https://registry.yarnpkg.com/@jest/types/-/types-26.0.1.tgz#b78333fbd113fa7aec8d39de24f88de8686dac67" +"@jest/types@^26.1.0": + version "26.1.0" + resolved "https://registry.yarnpkg.com/@jest/types/-/types-26.1.0.tgz#f8afaaaeeb23b5cad49dd1f7779689941dcb6057" dependencies: "@types/istanbul-lib-coverage" "^2.0.0" "@types/istanbul-reports" "^1.1.1" @@ -690,6 +690,16 @@ dependencies: "@sinonjs/commons" "^1.7.0" +"@types/babel__core@^7.0.0": + version "7.1.9" + resolved "https://registry.yarnpkg.com/@types/babel__core/-/babel__core-7.1.9.tgz#77e59d438522a6fb898fa43dc3455c6e72f3963d" + dependencies: + "@babel/parser" "^7.1.0" + "@babel/types" "^7.0.0" + "@types/babel__generator" "*" + "@types/babel__template" "*" + "@types/babel__traverse" "*" + "@types/babel__core@^7.1.7": version "7.1.7" resolved "https://registry.yarnpkg.com/@types/babel__core/-/babel__core-7.1.7.tgz#1dacad8840364a57c98d0dd4855c6dd3752c6b89" @@ -1068,15 +1078,15 @@ babel-jest@^25.5.1: graceful-fs "^4.2.4" slash "^3.0.0" -babel-jest@^26.0.1: - version "26.0.1" - resolved "https://registry.yarnpkg.com/babel-jest/-/babel-jest-26.0.1.tgz#450139ce4b6c17174b136425bda91885c397bc46" +babel-jest@^26.1.0: + version "26.1.0" + resolved "https://registry.yarnpkg.com/babel-jest/-/babel-jest-26.1.0.tgz#b20751185fc7569a0f135730584044d1cb934328" dependencies: - "@jest/transform" "^26.0.1" - "@jest/types" "^26.0.1" + "@jest/transform" "^26.1.0" + "@jest/types" "^26.1.0" "@types/babel__core" "^7.1.7" babel-plugin-istanbul "^6.0.0" - babel-preset-jest "^26.0.0" + babel-preset-jest "^26.1.0" chalk "^4.0.0" graceful-fs "^4.2.4" slash "^3.0.0" @@ -1099,12 +1109,13 @@ babel-plugin-jest-hoist@^25.5.0: "@babel/types" "^7.3.3" "@types/babel__traverse" "^7.0.6" -babel-plugin-jest-hoist@^26.0.0: - version "26.0.0" - resolved "https://registry.yarnpkg.com/babel-plugin-jest-hoist/-/babel-plugin-jest-hoist-26.0.0.tgz#fd1d35f95cf8849fc65cb01b5e58aedd710b34a8" +babel-plugin-jest-hoist@^26.1.0: + version "26.1.0" + resolved "https://registry.yarnpkg.com/babel-plugin-jest-hoist/-/babel-plugin-jest-hoist-26.1.0.tgz#c6a774da08247a28285620a64dfadbd05dd5233a" dependencies: "@babel/template" "^7.3.3" "@babel/types" "^7.3.3" + "@types/babel__core" "^7.0.0" "@types/babel__traverse" "^7.0.6" babel-preset-current-node-syntax@^0.1.2: @@ -1129,11 +1140,11 @@ babel-preset-jest@^25.5.0: babel-plugin-jest-hoist "^25.5.0" babel-preset-current-node-syntax "^0.1.2" -babel-preset-jest@^26.0.0: - version "26.0.0" - resolved "https://registry.yarnpkg.com/babel-preset-jest/-/babel-preset-jest-26.0.0.tgz#1eac82f513ad36c4db2e9263d7c485c825b1faa6" +babel-preset-jest@^26.1.0: + version "26.1.0" + resolved "https://registry.yarnpkg.com/babel-preset-jest/-/babel-preset-jest-26.1.0.tgz#612f714e5b457394acfd863793c564cbcdb7d1c1" dependencies: - babel-plugin-jest-hoist "^26.0.0" + babel-plugin-jest-hoist "^26.1.0" babel-preset-current-node-syntax "^0.1.2" balanced-match@^1.0.0: @@ -1966,15 +1977,15 @@ expect@^25.5.0: jest-message-util "^25.5.0" jest-regex-util "^25.2.6" -expect@^26.0.1: - version "26.0.1" - resolved "https://registry.yarnpkg.com/expect/-/expect-26.0.1.tgz#18697b9611a7e2725e20ba3ceadda49bc9865421" +expect@^26.1.0: + version "26.1.0" + resolved "https://registry.yarnpkg.com/expect/-/expect-26.1.0.tgz#8c62e31d0f8d5a8ebb186ee81473d15dd2fbf7c8" dependencies: - "@jest/types" "^26.0.1" + "@jest/types" "^26.1.0" ansi-styles "^4.0.0" jest-get-type "^26.0.0" - jest-matcher-utils "^26.0.1" - jest-message-util "^26.0.1" + jest-matcher-utils "^26.1.0" + jest-message-util "^26.1.0" jest-regex-util "^26.0.0" extend-shallow@^2.0.1: @@ -2637,26 +2648,26 @@ jest-changed-files@^25.5.0: execa "^3.2.0" throat "^5.0.0" -jest-circus@26.0.1: - version "26.0.1" - resolved "https://registry.yarnpkg.com/jest-circus/-/jest-circus-26.0.1.tgz#602c412ae8d31c5d436fa84c3a58944b166833fa" +jest-circus@26.1.0: + version "26.1.0" + resolved "https://registry.yarnpkg.com/jest-circus/-/jest-circus-26.1.0.tgz#3c6ef8669eb3b7a83eac27b6b7bec874d697b15f" dependencies: "@babel/traverse" "^7.1.0" - "@jest/environment" "^26.0.1" - "@jest/test-result" "^26.0.1" - "@jest/types" "^26.0.1" + "@jest/environment" "^26.1.0" + "@jest/test-result" "^26.1.0" + "@jest/types" "^26.1.0" chalk "^4.0.0" co "^4.6.0" dedent "^0.7.0" - expect "^26.0.1" + expect "^26.1.0" is-generator-fn "^2.0.0" - jest-each "^26.0.1" - jest-matcher-utils "^26.0.1" - jest-message-util "^26.0.1" - jest-runtime "^26.0.1" - jest-snapshot "^26.0.1" - jest-util "^26.0.1" - pretty-format "^26.0.1" + jest-each "^26.1.0" + jest-matcher-utils "^26.1.0" + jest-message-util "^26.1.0" + jest-runtime "^26.1.0" + jest-snapshot "^26.1.0" + jest-util "^26.1.0" + pretty-format "^26.1.0" stack-utils "^2.0.2" throat "^5.0.0" @@ -2703,28 +2714,28 @@ jest-config@^25.5.4: pretty-format "^25.5.0" realpath-native "^2.0.0" -jest-config@^26.0.1: - version "26.0.1" - resolved "https://registry.yarnpkg.com/jest-config/-/jest-config-26.0.1.tgz#096a3d4150afadf719d1fab00e9a6fb2d6d67507" +jest-config@^26.1.0: + version "26.1.0" + resolved "https://registry.yarnpkg.com/jest-config/-/jest-config-26.1.0.tgz#9074f7539acc185e0113ad6d22ed589c16a37a73" dependencies: "@babel/core" "^7.1.0" - "@jest/test-sequencer" "^26.0.1" - "@jest/types" "^26.0.1" - babel-jest "^26.0.1" + "@jest/test-sequencer" "^26.1.0" + "@jest/types" "^26.1.0" + babel-jest "^26.1.0" chalk "^4.0.0" deepmerge "^4.2.2" glob "^7.1.1" graceful-fs "^4.2.4" - jest-environment-jsdom "^26.0.1" - jest-environment-node "^26.0.1" + jest-environment-jsdom "^26.1.0" + jest-environment-node "^26.1.0" jest-get-type "^26.0.0" - jest-jasmine2 "^26.0.1" + jest-jasmine2 "^26.1.0" jest-regex-util "^26.0.0" - jest-resolve "^26.0.1" - jest-util "^26.0.1" - jest-validate "^26.0.1" + jest-resolve "^26.1.0" + jest-util "^26.1.0" + jest-validate "^26.1.0" micromatch "^4.0.2" - pretty-format "^26.0.1" + pretty-format "^26.1.0" jest-diff@^25.2.1, jest-diff@^25.5.0: version "25.5.0" @@ -2735,14 +2746,14 @@ jest-diff@^25.2.1, jest-diff@^25.5.0: jest-get-type "^25.2.6" pretty-format "^25.5.0" -jest-diff@^26.0.1: - version "26.0.1" - resolved "https://registry.yarnpkg.com/jest-diff/-/jest-diff-26.0.1.tgz#c44ab3cdd5977d466de69c46929e0e57f89aa1de" +jest-diff@^26.1.0: + version "26.1.0" + resolved "https://registry.yarnpkg.com/jest-diff/-/jest-diff-26.1.0.tgz#00a549bdc936c9691eb4dc25d1fbd78bf456abb2" dependencies: chalk "^4.0.0" diff-sequences "^26.0.0" jest-get-type "^26.0.0" - pretty-format "^26.0.1" + pretty-format "^26.1.0" jest-docblock@^25.3.0: version "25.3.0" @@ -2766,15 +2777,15 @@ jest-each@^25.5.0: jest-util "^25.5.0" pretty-format "^25.5.0" -jest-each@^26.0.1: - version "26.0.1" - resolved "https://registry.yarnpkg.com/jest-each/-/jest-each-26.0.1.tgz#633083061619302fc90dd8f58350f9d77d67be04" +jest-each@^26.1.0: + version "26.1.0" + resolved "https://registry.yarnpkg.com/jest-each/-/jest-each-26.1.0.tgz#e35449875009a22d74d1bda183b306db20f286f7" dependencies: - "@jest/types" "^26.0.1" + "@jest/types" "^26.1.0" chalk "^4.0.0" jest-get-type "^26.0.0" - jest-util "^26.0.1" - pretty-format "^26.0.1" + jest-util "^26.1.0" + pretty-format "^26.1.0" jest-environment-jsdom@^25.5.0: version "25.5.0" @@ -2787,15 +2798,15 @@ jest-environment-jsdom@^25.5.0: jest-util "^25.5.0" jsdom "^15.2.1" -jest-environment-jsdom@^26.0.1: - version "26.0.1" - resolved "https://registry.yarnpkg.com/jest-environment-jsdom/-/jest-environment-jsdom-26.0.1.tgz#217690852e5bdd7c846a4e3b50c8ffd441dfd249" +jest-environment-jsdom@^26.1.0: + version "26.1.0" + resolved "https://registry.yarnpkg.com/jest-environment-jsdom/-/jest-environment-jsdom-26.1.0.tgz#9dc7313ffe1b59761dad1fedb76e2503e5d37c5b" dependencies: - "@jest/environment" "^26.0.1" - "@jest/fake-timers" "^26.0.1" - "@jest/types" "^26.0.1" - jest-mock "^26.0.1" - jest-util "^26.0.1" + "@jest/environment" "^26.1.0" + "@jest/fake-timers" "^26.1.0" + "@jest/types" "^26.1.0" + jest-mock "^26.1.0" + jest-util "^26.1.0" jsdom "^16.2.2" jest-environment-node@^25.5.0: @@ -2809,15 +2820,15 @@ jest-environment-node@^25.5.0: jest-util "^25.5.0" semver "^6.3.0" -jest-environment-node@^26.0.1: - version "26.0.1" - resolved "https://registry.yarnpkg.com/jest-environment-node/-/jest-environment-node-26.0.1.tgz#584a9ff623124ff6eeb49e0131b5f7612b310b13" +jest-environment-node@^26.1.0: + version "26.1.0" + resolved "https://registry.yarnpkg.com/jest-environment-node/-/jest-environment-node-26.1.0.tgz#8bb387b3eefb132eab7826f9a808e4e05618960b" dependencies: - "@jest/environment" "^26.0.1" - "@jest/fake-timers" "^26.0.1" - "@jest/types" "^26.0.1" - jest-mock "^26.0.1" - jest-util "^26.0.1" + "@jest/environment" "^26.1.0" + "@jest/fake-timers" "^26.1.0" + "@jest/types" "^26.1.0" + jest-mock "^26.1.0" + jest-util "^26.1.0" jest-get-type@^25.2.6: version "25.2.6" @@ -2846,18 +2857,18 @@ jest-haste-map@^25.5.1: optionalDependencies: fsevents "^2.1.2" -jest-haste-map@^26.0.1: - version "26.0.1" - resolved "https://registry.yarnpkg.com/jest-haste-map/-/jest-haste-map-26.0.1.tgz#40dcc03c43ac94d25b8618075804d09cd5d49de7" +jest-haste-map@^26.1.0: + version "26.1.0" + resolved "https://registry.yarnpkg.com/jest-haste-map/-/jest-haste-map-26.1.0.tgz#ef31209be73f09b0d9445e7d213e1b53d0d1476a" dependencies: - "@jest/types" "^26.0.1" + "@jest/types" "^26.1.0" "@types/graceful-fs" "^4.1.2" anymatch "^3.0.3" fb-watchman "^2.0.0" graceful-fs "^4.2.4" - jest-serializer "^26.0.0" - jest-util "^26.0.1" - jest-worker "^26.0.0" + jest-serializer "^26.1.0" + jest-util "^26.1.0" + jest-worker "^26.1.0" micromatch "^4.0.2" sane "^4.0.3" walker "^1.0.7" @@ -2887,26 +2898,26 @@ jest-jasmine2@^25.5.4: pretty-format "^25.5.0" throat "^5.0.0" -jest-jasmine2@^26.0.1: - version "26.0.1" - resolved "https://registry.yarnpkg.com/jest-jasmine2/-/jest-jasmine2-26.0.1.tgz#947c40ee816636ba23112af3206d6fa7b23c1c1c" +jest-jasmine2@^26.1.0: + version "26.1.0" + resolved "https://registry.yarnpkg.com/jest-jasmine2/-/jest-jasmine2-26.1.0.tgz#4dfe349b2b2d3c6b3a27c024fd4cb57ac0ed4b6f" dependencies: "@babel/traverse" "^7.1.0" - "@jest/environment" "^26.0.1" - "@jest/source-map" "^26.0.0" - "@jest/test-result" "^26.0.1" - "@jest/types" "^26.0.1" + "@jest/environment" "^26.1.0" + "@jest/source-map" "^26.1.0" + "@jest/test-result" "^26.1.0" + "@jest/types" "^26.1.0" chalk "^4.0.0" co "^4.6.0" - expect "^26.0.1" + expect "^26.1.0" is-generator-fn "^2.0.0" - jest-each "^26.0.1" - jest-matcher-utils "^26.0.1" - jest-message-util "^26.0.1" - jest-runtime "^26.0.1" - jest-snapshot "^26.0.1" - jest-util "^26.0.1" - pretty-format "^26.0.1" + jest-each "^26.1.0" + jest-matcher-utils "^26.1.0" + jest-message-util "^26.1.0" + jest-runtime "^26.1.0" + jest-snapshot "^26.1.0" + jest-util "^26.1.0" + pretty-format "^26.1.0" throat "^5.0.0" jest-leak-detector@^25.5.0: @@ -2916,12 +2927,12 @@ jest-leak-detector@^25.5.0: jest-get-type "^25.2.6" pretty-format "^25.5.0" -jest-leak-detector@^26.0.1: - version "26.0.1" - resolved "https://registry.yarnpkg.com/jest-leak-detector/-/jest-leak-detector-26.0.1.tgz#79b19ab3f41170e0a78eb8fa754a116d3447fb8c" +jest-leak-detector@^26.1.0: + version "26.1.0" + resolved "https://registry.yarnpkg.com/jest-leak-detector/-/jest-leak-detector-26.1.0.tgz#039c3a07ebcd8adfa984b6ac015752c35792e0a6" dependencies: jest-get-type "^26.0.0" - pretty-format "^26.0.1" + pretty-format "^26.1.0" jest-matcher-utils@^25.5.0: version "25.5.0" @@ -2932,14 +2943,14 @@ jest-matcher-utils@^25.5.0: jest-get-type "^25.2.6" pretty-format "^25.5.0" -jest-matcher-utils@^26.0.1: - version "26.0.1" - resolved "https://registry.yarnpkg.com/jest-matcher-utils/-/jest-matcher-utils-26.0.1.tgz#12e1fc386fe4f14678f4cc8dbd5ba75a58092911" +jest-matcher-utils@^26.1.0: + version "26.1.0" + resolved "https://registry.yarnpkg.com/jest-matcher-utils/-/jest-matcher-utils-26.1.0.tgz#cf75a41bd413dda784f022de5a65a2a5c73a5c92" dependencies: chalk "^4.0.0" - jest-diff "^26.0.1" + jest-diff "^26.1.0" jest-get-type "^26.0.0" - pretty-format "^26.0.1" + pretty-format "^26.1.0" jest-message-util@^25.5.0: version "25.5.0" @@ -2954,12 +2965,12 @@ jest-message-util@^25.5.0: slash "^3.0.0" stack-utils "^1.0.1" -jest-message-util@^26.0.1: - version "26.0.1" - resolved "https://registry.yarnpkg.com/jest-message-util/-/jest-message-util-26.0.1.tgz#07af1b42fc450b4cc8e90e4c9cef11b33ce9b0ac" +jest-message-util@^26.1.0: + version "26.1.0" + resolved "https://registry.yarnpkg.com/jest-message-util/-/jest-message-util-26.1.0.tgz#52573fbb8f5cea443c4d1747804d7a238a3e233c" dependencies: "@babel/code-frame" "^7.0.0" - "@jest/types" "^26.0.1" + "@jest/types" "^26.1.0" "@types/stack-utils" "^1.0.1" chalk "^4.0.0" graceful-fs "^4.2.4" @@ -2973,11 +2984,11 @@ jest-mock@^25.5.0: dependencies: "@jest/types" "^25.5.0" -jest-mock@^26.0.1: - version "26.0.1" - resolved "https://registry.yarnpkg.com/jest-mock/-/jest-mock-26.0.1.tgz#7fd1517ed4955397cf1620a771dc2d61fad8fd40" +jest-mock@^26.1.0: + version "26.1.0" + resolved "https://registry.yarnpkg.com/jest-mock/-/jest-mock-26.1.0.tgz#80d8286da1f05a345fbad1bfd6fa49a899465d3d" dependencies: - "@jest/types" "^26.0.1" + "@jest/types" "^26.1.0" jest-pnp-resolver@^1.2.1: version "1.2.1" @@ -3013,15 +3024,15 @@ jest-resolve@^25.5.1: resolve "^1.17.0" slash "^3.0.0" -jest-resolve@^26.0.1: - version "26.0.1" - resolved "https://registry.yarnpkg.com/jest-resolve/-/jest-resolve-26.0.1.tgz#21d1ee06f9ea270a343a8893051aeed940cde736" +jest-resolve@^26.1.0: + version "26.1.0" + resolved "https://registry.yarnpkg.com/jest-resolve/-/jest-resolve-26.1.0.tgz#a530eaa302b1f6fa0479079d1561dd69abc00e68" dependencies: - "@jest/types" "^26.0.1" + "@jest/types" "^26.1.0" chalk "^4.0.0" graceful-fs "^4.2.4" jest-pnp-resolver "^1.2.1" - jest-util "^26.0.1" + jest-util "^26.1.0" read-pkg-up "^7.0.1" resolve "^1.17.0" slash "^3.0.0" @@ -3050,27 +3061,27 @@ jest-runner@^25.5.4: source-map-support "^0.5.6" throat "^5.0.0" -jest-runner@^26.0.1: - version "26.0.1" - resolved "https://registry.yarnpkg.com/jest-runner/-/jest-runner-26.0.1.tgz#ea03584b7ae4bacfb7e533d680a575a49ae35d50" +jest-runner@^26.1.0: + version "26.1.0" + resolved "https://registry.yarnpkg.com/jest-runner/-/jest-runner-26.1.0.tgz#457f7fc522afe46ca6db1dccf19f87f500b3288d" dependencies: - "@jest/console" "^26.0.1" - "@jest/environment" "^26.0.1" - "@jest/test-result" "^26.0.1" - "@jest/types" "^26.0.1" + "@jest/console" "^26.1.0" + "@jest/environment" "^26.1.0" + "@jest/test-result" "^26.1.0" + "@jest/types" "^26.1.0" chalk "^4.0.0" exit "^0.1.2" graceful-fs "^4.2.4" - jest-config "^26.0.1" + jest-config "^26.1.0" jest-docblock "^26.0.0" - jest-haste-map "^26.0.1" - jest-jasmine2 "^26.0.1" - jest-leak-detector "^26.0.1" - jest-message-util "^26.0.1" - jest-resolve "^26.0.1" - jest-runtime "^26.0.1" - jest-util "^26.0.1" - jest-worker "^26.0.0" + jest-haste-map "^26.1.0" + jest-jasmine2 "^26.1.0" + jest-leak-detector "^26.1.0" + jest-message-util "^26.1.0" + jest-resolve "^26.1.0" + jest-runtime "^26.1.0" + jest-util "^26.1.0" + jest-worker "^26.1.0" source-map-support "^0.5.6" throat "^5.0.0" @@ -3105,33 +3116,33 @@ jest-runtime@^25.5.4: strip-bom "^4.0.0" yargs "^15.3.1" -jest-runtime@^26.0.1: - version "26.0.1" - resolved "https://registry.yarnpkg.com/jest-runtime/-/jest-runtime-26.0.1.tgz#a121a6321235987d294168e282d52b364d7d3f89" +jest-runtime@^26.1.0: + version "26.1.0" + resolved "https://registry.yarnpkg.com/jest-runtime/-/jest-runtime-26.1.0.tgz#45a37af42115f123ed5c51f126c05502da2469cb" dependencies: - "@jest/console" "^26.0.1" - "@jest/environment" "^26.0.1" - "@jest/fake-timers" "^26.0.1" - "@jest/globals" "^26.0.1" - "@jest/source-map" "^26.0.0" - "@jest/test-result" "^26.0.1" - "@jest/transform" "^26.0.1" - "@jest/types" "^26.0.1" + "@jest/console" "^26.1.0" + "@jest/environment" "^26.1.0" + "@jest/fake-timers" "^26.1.0" + "@jest/globals" "^26.1.0" + "@jest/source-map" "^26.1.0" + "@jest/test-result" "^26.1.0" + "@jest/transform" "^26.1.0" + "@jest/types" "^26.1.0" "@types/yargs" "^15.0.0" chalk "^4.0.0" collect-v8-coverage "^1.0.0" exit "^0.1.2" glob "^7.1.3" graceful-fs "^4.2.4" - jest-config "^26.0.1" - jest-haste-map "^26.0.1" - jest-message-util "^26.0.1" - jest-mock "^26.0.1" + jest-config "^26.1.0" + jest-haste-map "^26.1.0" + jest-message-util "^26.1.0" + jest-mock "^26.1.0" jest-regex-util "^26.0.0" - jest-resolve "^26.0.1" - jest-snapshot "^26.0.1" - jest-util "^26.0.1" - jest-validate "^26.0.1" + jest-resolve "^26.1.0" + jest-snapshot "^26.1.0" + jest-util "^26.1.0" + jest-validate "^26.1.0" slash "^3.0.0" strip-bom "^4.0.0" yargs "^15.3.1" @@ -3142,9 +3153,9 @@ jest-serializer@^25.5.0: dependencies: graceful-fs "^4.2.4" -jest-serializer@^26.0.0: - version "26.0.0" - resolved "https://registry.yarnpkg.com/jest-serializer/-/jest-serializer-26.0.0.tgz#f6c521ddb976943b93e662c0d4d79245abec72a3" +jest-serializer@^26.1.0: + version "26.1.0" + resolved "https://registry.yarnpkg.com/jest-serializer/-/jest-serializer-26.1.0.tgz#72a394531fc9b08e173dc7d297440ac610d95022" dependencies: graceful-fs "^4.2.4" @@ -3168,24 +3179,24 @@ jest-snapshot@^25.5.1: pretty-format "^25.5.0" semver "^6.3.0" -jest-snapshot@^26.0.1: - version "26.0.1" - resolved "https://registry.yarnpkg.com/jest-snapshot/-/jest-snapshot-26.0.1.tgz#1baa942bd83d47b837a84af7fcf5fd4a236da399" +jest-snapshot@^26.1.0: + version "26.1.0" + resolved "https://registry.yarnpkg.com/jest-snapshot/-/jest-snapshot-26.1.0.tgz#c36ed1e0334bd7bd2fe5ad07e93a364ead7e1349" dependencies: "@babel/types" "^7.0.0" - "@jest/types" "^26.0.1" + "@jest/types" "^26.1.0" "@types/prettier" "^2.0.0" chalk "^4.0.0" - expect "^26.0.1" + expect "^26.1.0" graceful-fs "^4.2.4" - jest-diff "^26.0.1" + jest-diff "^26.1.0" jest-get-type "^26.0.0" - jest-matcher-utils "^26.0.1" - jest-message-util "^26.0.1" - jest-resolve "^26.0.1" - make-dir "^3.0.0" + jest-haste-map "^26.1.0" + jest-matcher-utils "^26.1.0" + jest-message-util "^26.1.0" + jest-resolve "^26.1.0" natural-compare "^1.4.0" - pretty-format "^26.0.1" + pretty-format "^26.1.0" semver "^7.3.2" jest-util@^25.5.0: @@ -3198,15 +3209,15 @@ jest-util@^25.5.0: is-ci "^2.0.0" make-dir "^3.0.0" -jest-util@^26.0.1: - version "26.0.1" - resolved "https://registry.yarnpkg.com/jest-util/-/jest-util-26.0.1.tgz#72c4c51177b695fdd795ca072a6f94e3d7cef00a" +jest-util@^26.1.0: + version "26.1.0" + resolved "https://registry.yarnpkg.com/jest-util/-/jest-util-26.1.0.tgz#80e85d4ba820decacf41a691c2042d5276e5d8d8" dependencies: - "@jest/types" "^26.0.1" + "@jest/types" "^26.1.0" chalk "^4.0.0" graceful-fs "^4.2.4" is-ci "^2.0.0" - make-dir "^3.0.0" + micromatch "^4.0.2" jest-validate@^25.5.0: version "25.5.0" @@ -3219,16 +3230,16 @@ jest-validate@^25.5.0: leven "^3.1.0" pretty-format "^25.5.0" -jest-validate@^26.0.1: - version "26.0.1" - resolved "https://registry.yarnpkg.com/jest-validate/-/jest-validate-26.0.1.tgz#a62987e1da5b7f724130f904725e22f4e5b2e23c" +jest-validate@^26.1.0: + version "26.1.0" + resolved "https://registry.yarnpkg.com/jest-validate/-/jest-validate-26.1.0.tgz#942c85ad3d60f78250c488a7f85d8f11a29788e7" dependencies: - "@jest/types" "^26.0.1" + "@jest/types" "^26.1.0" camelcase "^6.0.0" chalk "^4.0.0" jest-get-type "^26.0.0" leven "^3.1.0" - pretty-format "^26.0.1" + pretty-format "^26.1.0" jest-watcher@^25.5.0: version "25.5.0" @@ -3248,9 +3259,9 @@ jest-worker@^25.5.0: merge-stream "^2.0.0" supports-color "^7.0.0" -jest-worker@^26.0.0: - version "26.0.0" - resolved "https://registry.yarnpkg.com/jest-worker/-/jest-worker-26.0.0.tgz#4920c7714f0a96c6412464718d0c58a3df3fb066" +jest-worker@^26.1.0: + version "26.1.0" + resolved "https://registry.yarnpkg.com/jest-worker/-/jest-worker-26.1.0.tgz#65d5641af74e08ccd561c240e7db61284f82f33d" dependencies: merge-stream "^2.0.0" supports-color "^7.0.0" @@ -3964,11 +3975,11 @@ pretty-format@^25.2.1, pretty-format@^25.5.0: ansi-styles "^4.0.0" react-is "^16.12.0" -pretty-format@^26.0.1: - version "26.0.1" - resolved "https://registry.yarnpkg.com/pretty-format/-/pretty-format-26.0.1.tgz#a4fe54fe428ad2fd3413ca6bbd1ec8c2e277e197" +pretty-format@^26.1.0: + version "26.1.0" + resolved "https://registry.yarnpkg.com/pretty-format/-/pretty-format-26.1.0.tgz#272b9cd1f1a924ab5d443dc224899d7a65cb96ec" dependencies: - "@jest/types" "^26.0.1" + "@jest/types" "^26.1.0" ansi-regex "^5.0.0" ansi-styles "^4.0.0" react-is "^16.12.0" From df0bfb00e4d6f7b79cb4e3ce1dfb7072cbaee9cf Mon Sep 17 00:00:00 2001 From: "dependabot-preview[bot]" <27856297+dependabot-preview[bot]@users.noreply.github.com> Date: Thu, 25 Jun 2020 20:11:51 -0400 Subject: [PATCH 12/14] Bump @types/node from 14.0.13 to 14.0.14 (#343) Bumps [@types/node](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/node) from 14.0.13 to 14.0.14. - [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases) - [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/node) Signed-off-by: dependabot-preview[bot] Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com> --- package.json | 2 +- yarn.lock | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/package.json b/package.json index a6182714..cd6f2202 100644 --- a/package.json +++ b/package.json @@ -40,7 +40,7 @@ }, "devDependencies": { "@types/jest": "26.0.0", - "@types/node": "14.0.13", + "@types/node": "14.0.14", "eslint": "7.3.1", "eslint-plugin-github": "3.4.1", "eslint-plugin-jest": "23.17.1", diff --git a/yarn.lock b/yarn.lock index ff0bf25e..42b2d61b 100644 --- a/yarn.lock +++ b/yarn.lock @@ -771,9 +771,9 @@ version "7.0.4" resolved "https://registry.yarnpkg.com/@types/json-schema/-/json-schema-7.0.4.tgz#38fd73ddfd9b55abb1e1b2ed578cb55bd7b7d339" -"@types/node@*", "@types/node@14.0.13", "@types/node@>= 8": - version "14.0.13" - resolved "https://registry.yarnpkg.com/@types/node/-/node-14.0.13.tgz#ee1128e881b874c371374c1f72201893616417c9" +"@types/node@*", "@types/node@14.0.14", "@types/node@>= 8": + version "14.0.14" + resolved "https://registry.yarnpkg.com/@types/node/-/node-14.0.14.tgz#24a0b5959f16ac141aeb0c5b3cd7a15b7c64cbce" "@types/normalize-package-data@^2.4.0": version "2.4.0" From c4c5b7beaff8bf6070ce394368dc1fbd201d4264 Mon Sep 17 00:00:00 2001 From: "dependabot-preview[bot]" <27856297+dependabot-preview[bot]@users.noreply.github.com> Date: Thu, 25 Jun 2020 21:05:23 -0400 Subject: [PATCH 13/14] Bump @types/jest from 26.0.0 to 26.0.3 (#344) Bumps [@types/jest](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/jest) from 26.0.0 to 26.0.3. - [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases) - [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/jest) Signed-off-by: dependabot-preview[bot] Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com> --- package.json | 2 +- yarn.lock | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/package.json b/package.json index cd6f2202..99f9e987 100644 --- a/package.json +++ b/package.json @@ -39,7 +39,7 @@ "@actions/io": "1.0.2" }, "devDependencies": { - "@types/jest": "26.0.0", + "@types/jest": "26.0.3", "@types/node": "14.0.14", "eslint": "7.3.1", "eslint-plugin-github": "3.4.1", diff --git a/yarn.lock b/yarn.lock index 42b2d61b..d58aeff4 100644 --- a/yarn.lock +++ b/yarn.lock @@ -760,9 +760,9 @@ "@types/istanbul-lib-coverage" "*" "@types/istanbul-lib-report" "*" -"@types/jest@26.0.0": - version "26.0.0" - resolved "https://registry.yarnpkg.com/@types/jest/-/jest-26.0.0.tgz#a6d7573dffa9c68cbbdf38f2e0de26f159e11134" +"@types/jest@26.0.3": + version "26.0.3" + resolved "https://registry.yarnpkg.com/@types/jest/-/jest-26.0.3.tgz#79534e0e94857171c0edc596db0ebe7cb7863251" dependencies: jest-diff "^25.2.1" pretty-format "^25.2.1" From b71ad7535207f2e7e37c01f076725f98a5f37df9 Mon Sep 17 00:00:00 2001 From: James Ives Date: Fri, 26 Jun 2020 08:18:23 -0400 Subject: [PATCH 14/14] Silent Settings (#347) --- README.md | 3 +- __tests__/execute.test.ts | 8 ++-- __tests__/git.test.ts | 22 +++++++++ src/constants.ts | 5 +++ src/execute.ts | 10 +++-- src/git.ts | 95 ++++++++++++++++++++++++++++----------- 6 files changed, 108 insertions(+), 35 deletions(-) diff --git a/README.md b/README.md index 2f2b85ed..caa225a0 100644 --- a/README.md +++ b/README.md @@ -147,6 +147,7 @@ In addition to the deployment options you must also configure the following. | `CLEAN` | If your project generates hashed files on build you can use this option to automatically delete them from the deployment branch with each deploy. This option can be toggled on by setting it to `true`. | `with` | **No** | | `CLEAN_EXCLUDE` | If you need to use `CLEAN` but you'd like to preserve certain files or folders you can use this option. This should be formatted as an array but stored as a string. For example: `'["filename.js", "folder"]'` | `with` | **No** | | `SINGLE_COMMIT` | This option can be toggled to `true` if you'd prefer to have a single commit on the deployment branch instead of maintaining the full history. **Using this option will also cause any existing history to be wiped from the deployment branch**. | `with` | **No** | +| `SILENT` | Silences the action output preventing it from displaying git messages and error. | `with` | **No** | | `WORKSPACE` | This should point to where your project lives on the virtual machine. The GitHub Actions environment will set this for you. It is only neccersary to set this variable if you're using the node module. | `with` | **No** | With the action correctly configured you should see the workflow trigger the deployment under the configured conditions. @@ -320,4 +321,4 @@ If you're using a custom domain and require a `CNAME` file, or if you require th ### Debugging 🐝 -By default the git commands are hidden from the logs. If you'd like to turn them on you can set the `ACTIONS_STEP_DEBUG` environment variable to true within the [Settings/Secrets](https://help.github.com/en/actions/configuring-and-managing-workflows/creating-and-storing-encrypted-secrets#creating-encrypted-secrets) menu. If you're using this action in your own project as a node module via yarn or npm **you may expose your secrets if you toggle this on in a production environment**. You can learn more about debugging GitHub actions [here](https://github.com/actions/toolkit/blob/master/docs/action-debugging.md). +If you'd like to enable action debugging you can set the `ACTIONS_STEP_DEBUG` environment variable to true within the [Settings/Secrets](https://help.github.com/en/actions/configuring-and-managing-workflows/creating-and-storing-encrypted-secrets#creating-encrypted-secrets) menu. If you're using this action in your own project as a node module via yarn or npm **you may expose your secrets if you toggle this on in a production environment**. You can learn more about debugging GitHub actions [here](https://github.com/actions/toolkit/blob/master/docs/action-debugging.md). diff --git a/__tests__/execute.test.ts b/__tests__/execute.test.ts index 3999736b..14831ba8 100644 --- a/__tests__/execute.test.ts +++ b/__tests__/execute.test.ts @@ -6,9 +6,9 @@ jest.mock('@actions/exec', () => ({ })) describe('execute', () => { - it('should be called with the correct arguments', async () => { + it('should be called with the correct arguments when silent mode is enabled', async () => { stdout('hello') - await execute('echo Montezuma', './') + await execute('echo Montezuma', './', true) expect(exec).toBeCalledWith('echo Montezuma', [], { cwd: './', @@ -19,11 +19,11 @@ describe('execute', () => { }) }) - it('should not silence the input when INPUT_DEBUG is defined', async () => { + it('should not silence the input when action.silent is false', async () => { process.env['RUNNER_DEBUG'] = '1' stdout('hello') - await execute('echo Montezuma', './') + await execute('echo Montezuma', './', false) expect(exec).toBeCalledWith('echo Montezuma', [], { cwd: './', diff --git a/__tests__/git.test.ts b/__tests__/git.test.ts index 87381633..879620fd 100644 --- a/__tests__/git.test.ts +++ b/__tests__/git.test.ts @@ -33,6 +33,7 @@ describe('git', () => { describe('init', () => { it('should execute commands if a GitHub token is provided', async () => { Object.assign(action, { + silent: false, repositoryPath: 'JamesIves/github-pages-deploy-action', folder: 'assets', branch: 'branch', @@ -49,6 +50,7 @@ describe('git', () => { it('should execute commands if an Access Token is provided', async () => { Object.assign(action, { + silent: false, repositoryPath: 'JamesIves/github-pages-deploy-action', folder: 'assets', branch: 'branch', @@ -65,6 +67,7 @@ describe('git', () => { it('should execute commands if SSH is true', async () => { Object.assign(action, { + silent: false, repositoryPath: 'JamesIves/github-pages-deploy-action', folder: 'assets', branch: 'branch', @@ -82,6 +85,7 @@ describe('git', () => { it('should fail if there is no provided GitHub Token, Access Token or SSH bool', async () => { Object.assign(action, { + silent: false, repositoryPath: null, folder: 'assets', branch: 'branch', @@ -103,6 +107,7 @@ describe('git', () => { it('should fail if access token is defined but it is an empty string', async () => { Object.assign(action, { + silent: false, repositoryPath: null, folder: 'assets', branch: 'branch', @@ -125,6 +130,7 @@ describe('git', () => { it('should fail if there is no folder', async () => { Object.assign(action, { + silent: false, repositoryPath: 'JamesIves/github-pages-deploy-action', gitHubToken: '123', branch: 'branch', @@ -148,6 +154,7 @@ describe('git', () => { it('should fail if there is no provided repository path', async () => { Object.assign(action, { + silent: true, repositoryPath: null, folder: 'assets', branch: 'branch', @@ -172,6 +179,7 @@ describe('git', () => { it('should fail if the build folder begins with a /', async () => { Object.assign(action, { + silent: false, accessToken: '123', repositoryPath: 'JamesIves/github-pages-deploy-action', branch: 'branch', @@ -194,6 +202,7 @@ describe('git', () => { it('should fail if the build folder begins with a ./', async () => { Object.assign(action, { + silent: false, accessToken: '123', branch: 'branch', folder: './', @@ -215,6 +224,7 @@ describe('git', () => { it('should not fail if root is used', async () => { Object.assign(action, { + silent: false, repositoryPath: 'JamesIves/github-pages-deploy-action', accessToken: '123', branch: 'branch', @@ -235,6 +245,7 @@ describe('git', () => { describe('generateBranch', () => { it('should execute six commands', async () => { Object.assign(action, { + silent: false, accessToken: '123', branch: 'branch', folder: '.', @@ -250,6 +261,7 @@ describe('git', () => { it('should fail if there is no branch', async () => { Object.assign(action, { + silent: false, accessToken: '123', branch: null, folder: '.', @@ -272,6 +284,7 @@ describe('git', () => { describe('switchToBaseBranch', () => { it('should execute one command', async () => { Object.assign(action, { + silent: false, accessToken: '123', branch: 'branch', folder: '.', @@ -287,6 +300,7 @@ describe('git', () => { it('should execute one command if using custom baseBranch', async () => { Object.assign(action, { + silent: false, baseBranch: '123', accessToken: '123', branch: 'branch', @@ -303,6 +317,7 @@ describe('git', () => { it('should fail if one of the required parameters is not available', async () => { Object.assign(action, { + silent: false, baseBranch: '123', accessToken: null, gitHubToken: null, @@ -329,6 +344,7 @@ describe('git', () => { describe('deploy', () => { it('should execute commands', async () => { Object.assign(action, { + silent: false, folder: 'assets', branch: 'branch', gitHubToken: '123', @@ -348,6 +364,7 @@ describe('git', () => { it('should execute commands with single commit toggled', async () => { Object.assign(action, { + silent: false, folder: 'assets', branch: 'branch', gitHubToken: '123', @@ -368,6 +385,7 @@ describe('git', () => { it('should execute commands with clean options, ommits sha commit message', async () => { process.env.GITHUB_SHA = '' Object.assign(action, { + silent: false, folder: 'assets', branch: 'branch', gitHubToken: '123', @@ -388,6 +406,7 @@ describe('git', () => { it('should execute commands with clean options stored as an array instead', async () => { Object.assign(action, { + silent: false, folder: 'assets', branch: 'branch', gitHubToken: '123', @@ -408,6 +427,7 @@ describe('git', () => { it('should gracefully handle incorrectly formatted clean exclude items', async () => { Object.assign(action, { + silent: false, folder: '.', branch: 'branch', gitHubToken: '123', @@ -428,6 +448,7 @@ describe('git', () => { it('should stop early if there is nothing to commit', async () => { Object.assign(action, { + silent: false, folder: 'assets', branch: 'branch', gitHubToken: '123', @@ -446,6 +467,7 @@ describe('git', () => { it('should throw an error if one of the required parameters is not available', async () => { Object.assign(action, { + silent: false, folder: 'assets', branch: 'branch', ssh: null, diff --git a/src/constants.ts b/src/constants.ts index a2a89ac8..b9b4f832 100644 --- a/src/constants.ts +++ b/src/constants.ts @@ -38,6 +38,8 @@ export interface ActionInterface { root?: string /** Wipes the commit history from the deployment branch in favor of a single commit. */ singleCommit?: boolean | null + /** Determines if the action should run in silent mode or not. */ + silent?: boolean /** Set to true if you're using an ssh client in your build step. */ ssh?: boolean | null /** If you'd like to push the contents of the deployment folder into a specific directory on the deployment branch you can specify it here. */ @@ -87,6 +89,9 @@ export const action: ActionInterface = { singleCommit: !isNullOrUndefined(getInput('SINGLE_COMMIT')) ? getInput('SINGLE_COMMIT').toLowerCase() === 'true' : false, + silent: !isNullOrUndefined(getInput('SILENT')) + ? getInput('SILENT').toLowerCase() === 'true' + : false, ssh: !isNullOrUndefined(getInput('SSH')) ? getInput('SSH').toLowerCase() === 'true' : false, diff --git a/src/execute.ts b/src/execute.ts index 51307e2d..9cbcb839 100644 --- a/src/execute.ts +++ b/src/execute.ts @@ -1,4 +1,3 @@ -import {isDebug} from '@actions/core' import {exec} from '@actions/exec' let output: string @@ -8,13 +7,18 @@ let output: string * * @param {string} cmd - The command to execute. * @param {string} cwd - The current working directory. + * @param {boolean} silent - Determines if the in/out should be silenced or not. */ -export async function execute(cmd: string, cwd: string): Promise { +export async function execute( + cmd: string, + cwd: string, + silent?: boolean +): Promise { output = '' await exec(cmd, [], { // Silences the input unless the INPUT_DEBUG flag is set. - silent: isDebug() ? false : true, + silent, cwd, listeners: { stdout diff --git a/src/git.ts b/src/git.ts index fde9eee2..09c09fe1 100644 --- a/src/git.ts +++ b/src/git.ts @@ -16,15 +16,27 @@ export async function init(action: ActionInterface): Promise { info(`Deploying using ${action.tokenType}… 🔑`) info('Configuring git…') - await execute(`git init`, action.workspace) - await execute(`git config user.name "${action.name}"`, action.workspace) - await execute(`git config user.email "${action.email}"`, action.workspace) - await execute(`git remote rm origin`, action.workspace) + await execute(`git init`, action.workspace, action.silent) + await execute( + `git config user.name "${action.name}"`, + action.workspace, + action.silent + ) + await execute( + `git config user.email "${action.email}"`, + action.workspace, + action.silent + ) + await execute(`git remote rm origin`, action.workspace, action.silent) await execute( `git remote add origin ${action.repositoryPath}`, action.workspace ) - await execute(`git fetch --no-recurse-submodules`, action.workspace) + await execute( + `git fetch --no-recurse-submodules`, + action.workspace, + action.silent + ) info('Git configured… 🔧') } catch (error) { @@ -48,7 +60,8 @@ export async function switchToBaseBranch( `git checkout --progress --force ${ action.baseBranch ? action.baseBranch : action.defaultBranch }`, - action.workspace + action.workspace, + action.silent ) } catch (error) { throw new Error( @@ -68,17 +81,23 @@ export async function generateBranch(action: ActionInterface): Promise { info(`Creating the ${action.branch} branch…`) await switchToBaseBranch(action) - await execute(`git checkout --orphan ${action.branch}`, action.workspace) - await execute(`git reset --hard`, action.workspace) + await execute( + `git checkout --orphan ${action.branch}`, + action.workspace, + action.silent + ) + await execute(`git reset --hard`, action.workspace, action.silent) await execute( `git commit --allow-empty -m "Initial ${action.branch} commit"`, - action.workspace + action.workspace, + action.silent ) await execute( `git push --force ${action.repositoryPath} ${action.branch}`, - action.workspace + action.workspace, + action.silent ) - await execute(`git fetch`, action.workspace) + await execute(`git fetch`, action.workspace, action.silent) info(`Created the ${action.branch} branch… 🔧`) } catch (error) { @@ -125,10 +144,15 @@ export async function deploy(action: ActionInterface): Promise { // Checks out the base branch to begin the deployment process. await switchToBaseBranch(action) - await execute(`git fetch ${action.repositoryPath}`, action.workspace) + await execute( + `git fetch ${action.repositoryPath}`, + action.workspace, + action.silent + ) await execute( `git worktree add --checkout ${temporaryDeploymentDirectory} origin/${action.branch}`, - action.workspace + action.workspace, + action.silent ) // Ensures that items that need to be excluded from the clean job get parsed. @@ -173,12 +197,14 @@ export async function deploy(action: ActionInterface): Promise { ? `--exclude ${temporaryDeploymentDirectory}` : '' }`, - action.workspace + action.workspace, + action.silent ) const hasFilesToCommit = await execute( `git status --porcelain`, - `${action.workspace}/${temporaryDeploymentDirectory}` + `${action.workspace}/${temporaryDeploymentDirectory}`, + action.silent ) if (!hasFilesToCommit && !action.isTest) { @@ -188,44 +214,57 @@ export async function deploy(action: ActionInterface): Promise { // Commits to GitHub. await execute( `git add --all .`, - `${action.workspace}/${temporaryDeploymentDirectory}` + `${action.workspace}/${temporaryDeploymentDirectory}`, + action.silent ) await execute( `git checkout -b ${temporaryDeploymentBranch}`, - `${action.workspace}/${temporaryDeploymentDirectory}` + `${action.workspace}/${temporaryDeploymentDirectory}`, + action.silent ) await execute( `git commit -m "${commitMessage}" --quiet`, - `${action.workspace}/${temporaryDeploymentDirectory}` + `${action.workspace}/${temporaryDeploymentDirectory}`, + action.silent ) await execute( `git push --force ${action.repositoryPath} ${temporaryDeploymentBranch}:${action.branch}`, - `${action.workspace}/${temporaryDeploymentDirectory}` + `${action.workspace}/${temporaryDeploymentDirectory}`, + action.silent ) info(`Changes committed to the ${action.branch} branch… 📦`) if (action.singleCommit) { - await execute(`git fetch ${action.repositoryPath}`, action.workspace) + await execute( + `git fetch ${action.repositoryPath}`, + action.workspace, + action.silent + ) await execute( `git checkout --orphan ${action.branch}-temp`, - `${action.workspace}/${temporaryDeploymentDirectory}` + `${action.workspace}/${temporaryDeploymentDirectory}`, + action.silent ) await execute( `git add --all .`, - `${action.workspace}/${temporaryDeploymentDirectory}` + `${action.workspace}/${temporaryDeploymentDirectory}`, + action.silent ) await execute( `git commit -m "${commitMessage}" --quiet`, - `${action.workspace}/${temporaryDeploymentDirectory}` + `${action.workspace}/${temporaryDeploymentDirectory}`, + action.silent ) await execute( `git branch -M ${action.branch}-temp ${action.branch}`, - `${action.workspace}/${temporaryDeploymentDirectory}` + `${action.workspace}/${temporaryDeploymentDirectory}`, + action.silent ) await execute( `git push origin ${action.branch} --force`, - `${action.workspace}/${temporaryDeploymentDirectory}` + `${action.workspace}/${temporaryDeploymentDirectory}`, + action.silent ) info('Cleared git history… 🚿') @@ -233,7 +272,8 @@ export async function deploy(action: ActionInterface): Promise { await execute( `git checkout --progress --force ${action.defaultBranch}`, - action.workspace + action.workspace, + action.silent ) return Status.SUCCESS @@ -249,7 +289,8 @@ export async function deploy(action: ActionInterface): Promise { info('Running post deployment cleanup jobs… 🗑️') await execute( `git worktree remove ${temporaryDeploymentDirectory} --force`, - action.workspace + action.workspace, + action.silent ) await rmRF(temporaryDeploymentDirectory) }