mirror of
https://github.com/toeverything/AFFiNE.git
synced 2026-02-14 05:14:54 +00:00
chore: support http proxy in bump script (#8098)
This commit is contained in:
@@ -11,6 +11,7 @@ import {
|
||||
Sort,
|
||||
} from '@napi-rs/simple-git';
|
||||
import chalk from 'chalk';
|
||||
import { ProxyAgent, setGlobalDispatcher } from 'undici';
|
||||
|
||||
import corePackage from '../../packages/frontend/core/package.json' assert { type: 'json' };
|
||||
|
||||
@@ -32,6 +33,10 @@ if (oldHash === latestHash) {
|
||||
process.exit(0);
|
||||
}
|
||||
|
||||
if (process.env.http_proxy) {
|
||||
setGlobalDispatcher(new ProxyAgent(process.env.http_proxy));
|
||||
}
|
||||
|
||||
console.info(`Upgrade blocksuite from ${oldHash} -> ${latestHash}`);
|
||||
|
||||
const blockSuiteDeps = execSync(`yarn info -A --name-only --json`, {
|
||||
|
||||
Reference in New Issue
Block a user