feat: Initial clean release of CHM
一些检查失败了
automerge / automerge (push) Has been cancelled
react-native-android-build-apk / AssembleRelease (push) Has been cancelled
Build macOS M1 / Main (push) Has been cancelled
Joplin Continuous Integration / Main (macos-15-intel) (push) Has been cancelled
Joplin Continuous Integration / Main (ubuntu-22.04) (push) Has been cancelled
Joplin Continuous Integration / Main (ubuntu-22.04-arm) (push) Has been cancelled
Joplin Continuous Integration / Main (windows-11-vs2026-arm) (push) Has been cancelled
Joplin Continuous Integration / Main (windows-2025) (push) Has been cancelled
Joplin Continuous Integration / ServerDockerImage (ubuntu-22.04) (push) Has been cancelled
Joplin Continuous Integration / ServerDockerImage (ubuntu-22.04-arm) (push) Has been cancelled
Joplin UI tests / Main (ubuntu-22.04) (push) Has been cancelled
Joplin UI tests / Main (windows-2025) (push) Has been cancelled
Joplin UI tests / Mobile (push) Has been cancelled
Close stale issues / ProcessStaleIssues (push) Has been cancelled
一些检查失败了
automerge / automerge (push) Has been cancelled
react-native-android-build-apk / AssembleRelease (push) Has been cancelled
Build macOS M1 / Main (push) Has been cancelled
Joplin Continuous Integration / Main (macos-15-intel) (push) Has been cancelled
Joplin Continuous Integration / Main (ubuntu-22.04) (push) Has been cancelled
Joplin Continuous Integration / Main (ubuntu-22.04-arm) (push) Has been cancelled
Joplin Continuous Integration / Main (windows-11-vs2026-arm) (push) Has been cancelled
Joplin Continuous Integration / Main (windows-2025) (push) Has been cancelled
Joplin Continuous Integration / ServerDockerImage (ubuntu-22.04) (push) Has been cancelled
Joplin Continuous Integration / ServerDockerImage (ubuntu-22.04-arm) (push) Has been cancelled
Joplin UI tests / Main (ubuntu-22.04) (push) Has been cancelled
Joplin UI tests / Main (windows-2025) (push) Has been cancelled
Joplin UI tests / Mobile (push) Has been cancelled
Close stale issues / ProcessStaleIssues (push) Has been cancelled
这个提交包含在:
@@ -0,0 +1,54 @@
|
||||
const { execCommand } = require('@joplin/utils');
|
||||
const yargs = require('yargs');
|
||||
|
||||
async function main() {
|
||||
const argv = yargs.argv;
|
||||
if (!argv.profile) throw new Error('OneNote build: profile value is missing');
|
||||
if (!['release', 'dev'].includes(argv.profile)) throw new Error('OneNote build: profile value is invalid');
|
||||
const isDevBuild = argv.profile === 'dev';
|
||||
|
||||
if (!isDevBuild && !process.env.IS_CONTINUOUS_INTEGRATION) {
|
||||
// eslint-disable-next-line no-console
|
||||
console.info([
|
||||
'----------------------------------------------------------------\n' +
|
||||
'Not building onenote-converter because it is not a continuous integration environment.',
|
||||
'',
|
||||
'Either:',
|
||||
' - Re-run with the IS_CONTINUOUS_INTEGRATION environment variable set to 1.',
|
||||
' - Run "yarn buildDev" to create a development build.',
|
||||
'----------------------------------------------------------------',
|
||||
].join('\n'));
|
||||
return;
|
||||
}
|
||||
|
||||
// Sometimes the onenote-converter build needs to be disabled in CI.
|
||||
if (process.env.SKIP_ONENOTE_CONVERTER_BUILD) {
|
||||
// eslint-disable-next-line no-console
|
||||
console.info('SKIP_ONENOTE_CONVERTER_BUILD was set. The onenote-converter package will not be built.');
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
const buildCommand = `wasm-pack build --target nodejs --${argv.profile} ./renderer`;
|
||||
|
||||
// Retry to work around intermittent clang linker segfaults on macOS CI runners.
|
||||
await execCommand(buildCommand, { retryCount: 3 });
|
||||
|
||||
if (isDevBuild) return;
|
||||
|
||||
// If release build, remove intermediary folder to decrease size of release
|
||||
const removeIntermediaryFolder = 'cargo clean';
|
||||
|
||||
await execCommand(removeIntermediaryFolder);
|
||||
}
|
||||
|
||||
// eslint-disable-next-line promise/prefer-await-to-then
|
||||
main().catch((error) => {
|
||||
console.error('Fatal error', error);
|
||||
if (error.stderr.includes('No such file or directory (os error 2)')) {
|
||||
console.error('----------------------------------------------------------------');
|
||||
console.error('Rust toolchain is missing, please install it: https://rustup.rs/');
|
||||
console.error('----------------------------------------------------------------');
|
||||
}
|
||||
process.exit(1);
|
||||
});
|
||||
@@ -0,0 +1,12 @@
|
||||
const { execCommand } = require('@joplin/utils');
|
||||
|
||||
if (!process.env.IS_CONTINUOUS_INTEGRATION || process.env.SKIP_ONENOTE_CONVERTER_BUILD) {
|
||||
// eslint-disable-next-line no-console
|
||||
console.info([
|
||||
'Skipping tests. Either SKIP_ONENOTE_CONVERTER_BUILD is enabled or IS_CONTINUOUS_INTEGRATION is unset.',
|
||||
'Consider running the tests manually with the "cargo test" command.',
|
||||
].join('\n'));
|
||||
return;
|
||||
}
|
||||
|
||||
void execCommand('cargo test');
|
||||
在新工单中引用
屏蔽一个用户