From 5071309de00fc7407ebc5f341738ec2b7bd98c32 Mon Sep 17 00:00:00 2001 From: Charlie Drage Date: Tue, 9 Jan 2024 15:35:18 -0500 Subject: [PATCH] fixes for folder and image selection Signed-off-by: Charlie Drage --- package.json | 5 ++++- src/extension.ts | 7 ++++--- 2 files changed, 8 insertions(+), 4 deletions(-) diff --git a/package.json b/package.json index 5f02210f..26d6f01b 100644 --- a/package.json +++ b/package.json @@ -45,7 +45,10 @@ "badges/imagesList": [ { "when": "ostree.bootable in imageLabelKeys", - "badge": "bootable" + "badge": { + "name": "bootc", + "style": "bg-green-600" + } } ] } diff --git a/src/extension.ts b/src/extension.ts index 1110e67a..2cb98438 100644 --- a/src/extension.ts +++ b/src/extension.ts @@ -19,6 +19,7 @@ import type { ContainerCreateOptions, ExtensionContext } from '@podman-desktop/api'; import * as extensionApi from '@podman-desktop/api'; import { BootC } from './bootc'; +import * as os from 'node:os'; let bootc: BootC | undefined; const bootcImageBuilderContainerName = '-bootc-image-builder'; @@ -32,7 +33,7 @@ export async function activate(extensionContext: ExtensionContext): Promise { - const selectedType = await extensionApi.window.showQuickPick(['.oci', '.qcow2', '.ami', '.iso'], { + const selectedType = await extensionApi.window.showQuickPick(['qcow2', 'ami', 'iso'], { placeHolder: 'Select image type', }); if (!selectedType) @@ -40,7 +41,7 @@ export async function activate(extensionContext: ExtensionContext): Promise/disk. // in the directory provided - Cmd: [image.name,"--output","/tmp/"], + Cmd: [image.name,"--type", type, "--output","/tmp/" + type], }; try { await extensionApi.containerEngine.createContainer(image.engineId, options);