From c28661c916186892638a3848e12f24ddd70cafb8 Mon Sep 17 00:00:00 2001 From: Kenji Miyake Date: Sat, 29 Jan 2022 17:34:55 +0900 Subject: [PATCH 1/2] fix: add '--' to checkout command to avoid ambiguity Signed-off-by: Kenji Miyake --- dist/index.js | 2 ++ src/git-command-manager.ts | 2 ++ 2 files changed, 4 insertions(+) diff --git a/dist/index.js b/dist/index.js index b2024d089..77ba7a173 100644 --- a/dist/index.js +++ b/dist/index.js @@ -650,6 +650,8 @@ class GitCommandManager { else { args.push(ref); } + // https://github.com/git/git/commit/a047fafc7866cc4087201e284dc1f53e8f9a32d5 + args.push('--'); yield this.exec(args); }); } diff --git a/src/git-command-manager.ts b/src/git-command-manager.ts index 8dc6a9b51..08b2f3d80 100644 --- a/src/git-command-manager.ts +++ b/src/git-command-manager.ts @@ -32,6 +32,8 @@ export class GitCommandManager { } else { args.push(ref) } + // https://github.com/git/git/commit/a047fafc7866cc4087201e284dc1f53e8f9a32d5 + args.push('--'); await this.exec(args) } From 92e6d1ac44e67251193b07097b6903e12e8dea3d Mon Sep 17 00:00:00 2001 From: Kenji Miyake <31987104+kenji-miyake@users.noreply.github.com> Date: Sun, 30 Jan 2022 22:16:37 +0900 Subject: [PATCH 2/2] Update src/git-command-manager.ts Co-authored-by: Peter Evans <18365890+peter-evans@users.noreply.github.com> --- src/git-command-manager.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/git-command-manager.ts b/src/git-command-manager.ts index 08b2f3d80..367f796c0 100644 --- a/src/git-command-manager.ts +++ b/src/git-command-manager.ts @@ -33,7 +33,7 @@ export class GitCommandManager { args.push(ref) } // https://github.com/git/git/commit/a047fafc7866cc4087201e284dc1f53e8f9a32d5 - args.push('--'); + args.push('--') await this.exec(args) }