From b88e8e76cb4f6a285c0e592a279a12972e0276b9 Mon Sep 17 00:00:00 2001 From: James Addison Date: Sun, 10 Oct 2021 17:47:51 +0100 Subject: [PATCH] Throw an error when both 'platform' and 'arch' options are supplied during a build --- src/buildah.ts | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/buildah.ts b/src/buildah.ts index 3068049..db351c4 100644 --- a/src/buildah.ts +++ b/src/buildah.ts @@ -186,6 +186,10 @@ export class BuildahCli implements Buildah { ): Promise { // ghCore.info(`${EXECUTABLE} ${args.join(" ")}`) + if (args.arch && args.platform) { + throw new Error("The --platform option may not be used in combination with the --arch option."); + } + let stdout = ""; let stderr = "";