- Changed external links in settings-test.md and package.json to point to the new domestic website (guanzhangai.cn). - Updated electron-builder.yml to publish updates from the new domestic URL. - Introduced a new storage client for Tencent COS and refactored existing R2 client code to support both storage options. - Implemented environment variable checks and configurations for Tencent COS and Cloudflare R2. - Added tests for release storage configuration and ensured proper handling of live publish locks. - Updated telemetry service to use the new official website URL for event reporting.
22 lines
721 B
JavaScript
22 lines
721 B
JavaScript
import process from 'node:process'
|
|
import { DOMESTIC_DOWNLOAD_BASE_URL } from './config.mjs'
|
|
|
|
const plan = {
|
|
mode: 'dry-run',
|
|
storage: 'Tencent COS',
|
|
bucket: String(process.env.COS_BUCKET || 'ncurator-1324873382'),
|
|
region: String(process.env.COS_REGION || 'ap-guangzhou'),
|
|
publicBaseUrl: String(process.env.COS_PUBLIC_BASE_URL || DOMESTIC_DOWNLOAD_BASE_URL),
|
|
writes: [
|
|
'artifacts/<platform>/<tag>/*',
|
|
'release-status/<tag>/<platform>.json',
|
|
'updates/latest/latest*.yml',
|
|
'releases/latest/<platform>.json',
|
|
'downloads/latest/*'
|
|
],
|
|
networkRequests: 0,
|
|
note: 'This command never uploads, deletes, tags, commits, or pushes.'
|
|
}
|
|
|
|
process.stdout.write(`${JSON.stringify(plan, null, 2)}\n`)
|