Skip to content

armgit / Pake

Public Imported from GitHub
0

Turn any website into a lightweight desktop app with one command, on macOS, Windows and Linux.

Auto-fix formatting issues

GitHub Action00f29f13a4c5
diff --git a/bin/options/icon.ts b/bin/options/icon.ts
index 6a3fc238..da85716c 100644
--- a/bin/options/icon.ts
+++ b/bin/options/icon.ts
@@ -468,15 +468,16 @@ export async function downloadIcon(
clearTimeout(timeoutId);
if (!response.ok) {
- if (response.status === 404 && !showSpinner) {
- return null;
- }
- throw new Error(`HTTP ${response.status} ${response.statusText}`);
+ if (response.status === 404 && !showSpinner) {
+ return null;
+ }
+ throw new Error(`HTTP ${response.status} ${response.statusText}`);
}
const arrayBuffer = await response.arrayBuffer();
- if (!arrayBuffer || arrayBuffer.byteLength < ICON_CONFIG.minFileSize) return null;
+ if (!arrayBuffer || arrayBuffer.byteLength < ICON_CONFIG.minFileSize)
+ return null;
const fileDetails = await fileTypeFromBuffer(arrayBuffer);
if (
@@ -491,9 +492,12 @@ export async function downloadIcon(
clearTimeout(timeoutId);
if (showSpinner) {
if (error instanceof Error && error.name === 'AbortError') {
- logger.error('Icon download timed out!');
+ logger.error('Icon download timed out!');
} else {
- logger.error('Icon download failed!', error instanceof Error ? error.message : String(error));
+ logger.error(
+ 'Icon download failed!',
+ error instanceof Error ? error.message : String(error),
+ );
}
}
return null;
diff --git a/tests/index.js b/tests/index.js
index 1cc6a525..0b08ace1 100644
--- a/tests/index.js
+++ b/tests/index.js
@@ -1435,17 +1435,19 @@ runner
// Run release workflow tests as part of the standard suite
// We skip this if builder tests are explicitly disabled (often used for quick checks)
if (success && options.realBuild) {
- console.log("\n📦 Running Release Workflow Test...");
- console.log(" (This mimics the GitHub Actions release process for popular apps)");
+ console.log("\n📦 Running Release Workflow Test...");
+ console.log(
+ " (This mimics the GitHub Actions release process for popular apps)",
+ );
- // Pass skipCliBuild=true since "npm test" already builds the CLI
- const releaseTester = new ReleaseBuildTest();
- const releaseSuccess = await releaseTester.run({ skipCliBuild: true });
+ // Pass skipCliBuild=true since "npm test" already builds the CLI
+ const releaseTester = new ReleaseBuildTest();
+ const releaseSuccess = await releaseTester.run({ skipCliBuild: true });
- if (!releaseSuccess) {
- console.error("\n❌ Release workflow tests failed");
- process.exit(1);
- }
+ if (!releaseSuccess) {
+ console.error("\n❌ Release workflow tests failed");
+ process.exit(1);
+ }
}
process.exit(success ? 0 : 1);
diff --git a/tests/release.js b/tests/release.js
index b0c4d171..7c4a8f3e 100755
--- a/tests/release.js
+++ b/tests/release.js
@@ -79,7 +79,7 @@ class ReleaseBuildTest {
// Check files immediately after build
const outputFiles = this.findOutputFiles(config.name);
if (outputFiles.length === 0) {
- throw new Error("No output files generated");
+ throw new Error("No output files generated");
}
} catch (buildError) {
throw new Error(`Build failed: ${buildError.message}`);
@@ -162,13 +162,13 @@ class ReleaseBuildTest {
// Build CLI first (unless skipped)
if (!options.skipCliBuild) {
- this.log("INFO", "🔨 Building CLI...");
- try {
- execSync(`pnpm run cli:build`, { stdio: "pipe" });
- } catch (e) {
- this.log("ERROR", "Failed to build CLI");
- return false;
- }
+ this.log("INFO", "🔨 Building CLI...");
+ try {
+ execSync(`pnpm run cli:build`, { stdio: "pipe" });
+ } catch (e) {
+ this.log("ERROR", "Failed to build CLI");
+ return false;
+ }
}
console.log(`Testing apps: ${TEST_APPS.join(", ")}`);