mirror of
https://github.com/wu736139669/hapi.git
synced 2026-08-05 06:24:37 +00:00
Clean up cross-package build coupling
This commit is contained in:
@@ -172,8 +172,8 @@ export function getTunwgPath(): string {
|
||||
return join(runtimePath(), 'tools', 'tunwg', tunwgBinary);
|
||||
}
|
||||
|
||||
// Development mode: use downloaded binary from hub/tools/tunwg
|
||||
// Development mode: use downloaded binary from shared/tools/tunwg
|
||||
const platformDir = getPlatformDir();
|
||||
const devBinaryName = isWin ? `tunwg-${platformDir}.exe` : `tunwg-${platformDir}`;
|
||||
return join(__dirname, '..', '..', '..', 'hub', 'tools', 'tunwg', devBinaryName);
|
||||
return join(__dirname, '..', '..', '..', 'shared', 'tools', 'tunwg', devBinaryName);
|
||||
}
|
||||
|
||||
@@ -4,7 +4,7 @@ import difftasticArchiveLicense from '../../tools/archives/difftastic-LICENSE' a
|
||||
import ripgrepArchiveLicense from '../../tools/archives/ripgrep-LICENSE' assert { type: 'file' };
|
||||
import difftasticLicense from '../../tools/licenses/difftastic-LICENSE' assert { type: 'file' };
|
||||
import ripgrepLicense from '../../tools/licenses/ripgrep-LICENSE' assert { type: 'file' };
|
||||
import tunwgLicense from '../../../hub/tools/tunwg/LICENSE' assert { type: 'file' };
|
||||
import tunwgLicense from '../../../shared/tools/tunwg/LICENSE' assert { type: 'file' };
|
||||
|
||||
export interface EmbeddedAsset {
|
||||
relativePath: string;
|
||||
@@ -35,7 +35,7 @@ async function selectEmbeddedAssets(): Promise<EmbeddedAsset[]> {
|
||||
] = await Promise.all([
|
||||
import('../../tools/archives/difftastic-arm64-darwin.tar.gz', { assert: { type: 'file' } }),
|
||||
import('../../tools/archives/ripgrep-arm64-darwin.tar.gz', { assert: { type: 'file' } }),
|
||||
import('../../../hub/tools/tunwg/tunwg-arm64-darwin', { assert: { type: 'file' } })
|
||||
import('../../../shared/tools/tunwg/tunwg-arm64-darwin', { assert: { type: 'file' } })
|
||||
]);
|
||||
return [
|
||||
...COMMON_ASSETS,
|
||||
@@ -53,7 +53,7 @@ async function selectEmbeddedAssets(): Promise<EmbeddedAsset[]> {
|
||||
] = await Promise.all([
|
||||
import('../../tools/archives/difftastic-x64-darwin.tar.gz', { assert: { type: 'file' } }),
|
||||
import('../../tools/archives/ripgrep-x64-darwin.tar.gz', { assert: { type: 'file' } }),
|
||||
import('../../../hub/tools/tunwg/tunwg-x64-darwin', { assert: { type: 'file' } })
|
||||
import('../../../shared/tools/tunwg/tunwg-x64-darwin', { assert: { type: 'file' } })
|
||||
]);
|
||||
return [
|
||||
...COMMON_ASSETS,
|
||||
@@ -71,7 +71,7 @@ async function selectEmbeddedAssets(): Promise<EmbeddedAsset[]> {
|
||||
] = await Promise.all([
|
||||
import('../../tools/archives/difftastic-arm64-linux.tar.gz', { assert: { type: 'file' } }),
|
||||
import('../../tools/archives/ripgrep-arm64-linux.tar.gz', { assert: { type: 'file' } }),
|
||||
import('../../../hub/tools/tunwg/tunwg-arm64-linux', { assert: { type: 'file' } })
|
||||
import('../../../shared/tools/tunwg/tunwg-arm64-linux', { assert: { type: 'file' } })
|
||||
]);
|
||||
return [
|
||||
...COMMON_ASSETS,
|
||||
@@ -89,7 +89,7 @@ async function selectEmbeddedAssets(): Promise<EmbeddedAsset[]> {
|
||||
] = await Promise.all([
|
||||
import('../../tools/archives/difftastic-x64-linux.tar.gz', { assert: { type: 'file' } }),
|
||||
import('../../tools/archives/ripgrep-x64-linux.tar.gz', { assert: { type: 'file' } }),
|
||||
import('../../../hub/tools/tunwg/tunwg-x64-linux', { assert: { type: 'file' } })
|
||||
import('../../../shared/tools/tunwg/tunwg-x64-linux', { assert: { type: 'file' } })
|
||||
]);
|
||||
return [
|
||||
...COMMON_ASSETS,
|
||||
@@ -107,7 +107,7 @@ async function selectEmbeddedAssets(): Promise<EmbeddedAsset[]> {
|
||||
] = await Promise.all([
|
||||
import('../../tools/archives/difftastic-x64-win32.tar.gz', { assert: { type: 'file' } }),
|
||||
import('../../tools/archives/ripgrep-x64-win32.tar.gz', { assert: { type: 'file' } }),
|
||||
import('../../../hub/tools/tunwg/tunwg-x64-win32.exe', { assert: { type: 'file' } })
|
||||
import('../../../shared/tools/tunwg/tunwg-x64-win32.exe', { assert: { type: 'file' } })
|
||||
]);
|
||||
return [
|
||||
...COMMON_ASSETS,
|
||||
|
||||
Reference in New Issue
Block a user