From c9525e013b3d36d4ee86eb820a06417004e5a1fe Mon Sep 17 00:00:00 2001 From: Quinlan Jung Date: Tue, 4 Feb 2025 11:35:18 -0800 Subject: [PATCH] Reapply "[eas-cli] popup website in fingerprint:compare (#2859)" (#2862) This reverts commit 528988dc0f53b17fa1cce37c3954d548bc188be7. --- CHANGELOG.md | 1 + .../eas-cli/src/commands/fingerprint/compare.ts | 14 ++++++++++++++ 2 files changed, 15 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 52ca6e28b9..e61a3e1d99 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -37,6 +37,7 @@ This is the log of notable changes to EAS CLI and related packages. - Add update support for fingerprint:compare. ([#2850](https://github.com/expo/eas-cli/pull/2850) by [@quinlanj](https://github.com/quinlanj)) - Add update group id support for fingerprint:compare. ([#2851](https://github.com/expo/eas-cli/pull/2851) by [@quinlanj](https://github.com/quinlanj)) - Add better interactive support for fingerprint:compare. ([#2854](https://github.com/expo/eas-cli/pull/2854) by [@quinlanj](https://github.com/quinlanj)) +- Popup website in fingerprint:compare. ([#2859](https://github.com/expo/eas-cli/pull/2859) by [@quinlanj](https://github.com/quinlanj)) ## [14.7.1](https://github.com/expo/eas-cli/releases/tag/v14.7.1) - 2025-01-31 diff --git a/packages/eas-cli/src/commands/fingerprint/compare.ts b/packages/eas-cli/src/commands/fingerprint/compare.ts index 30fc1a44d7..2873f6225c 100644 --- a/packages/eas-cli/src/commands/fingerprint/compare.ts +++ b/packages/eas-cli/src/commands/fingerprint/compare.ts @@ -1,5 +1,6 @@ import { Platform, Workflow } from '@expo/eas-build-job'; import { Flags } from '@oclif/core'; +import openBrowserAsync from 'better-opn'; import chalk from 'chalk'; import { getExpoWebsiteBaseUrl } from '../../api'; @@ -229,6 +230,19 @@ export default class FingerprintCompare extends EasCommand { for (const diff of contentDiffs) { printContentDiff(diff); } + + if (nonInteractive) { + return; + } + + const project = await AppQuery.byIdAsync(graphqlClient, projectId); + const fingerprintCompareUrl = new URL( + `/accounts/${project.ownerAccount.name}/projects/${project.name}/fingerprint/compare`, + getExpoWebsiteBaseUrl() + ); + fingerprintCompareUrl.searchParams.set('a', firstFingerprintInfo.fingerprint.hash); + fingerprintCompareUrl.searchParams.set('b', secondFingerprintInfo.fingerprint.hash); + await openBrowserAsync(fingerprintCompareUrl.toString()); } }