mirror of
https://github.com/ksyasuda/SubMiner.git
synced 2026-04-08 10:19:21 -07:00
docs: add mpv.launchMode to config docs, add changelog:docs generator, format
- Document the new mpv.launchMode option in the configuration docs page - Add changelog:docs command to auto-generate docs-site/changelog.md from root CHANGELOG.md - Add breaking changes support to the changelog fragment generator - Fix docs-sync test to only compare current minor release headings - Apply prettier formatting to source files
This commit is contained in:
@@ -125,10 +125,7 @@ function titleOverlapScore(expectedTitle: string, candidateTitle: string): numbe
|
||||
if (!expected || !candidate) return 0;
|
||||
|
||||
if (candidate.includes(expected)) return 120;
|
||||
if (
|
||||
candidate.split(' ').length >= 2 &&
|
||||
` ${expected} `.includes(` ${candidate} `)
|
||||
) {
|
||||
if (candidate.split(' ').length >= 2 && ` ${expected} `.includes(` ${candidate} `)) {
|
||||
return 90;
|
||||
}
|
||||
|
||||
|
||||
@@ -715,18 +715,18 @@ function runFindAppBinaryWindowsInstallDirCase(): void {
|
||||
process.env.SUBMINER_BINARY_PATH = installDir;
|
||||
|
||||
withPlatform('win32', () => {
|
||||
withExistsAndStatSyncStubs(
|
||||
{ existingPaths: [appExe], directoryPaths: [installDir] },
|
||||
() => {
|
||||
withAccessSyncStub(
|
||||
(filePath) => filePath === appExe,
|
||||
() => {
|
||||
const result = findAppBinary(path.win32.join(baseDir, 'launcher', 'SubMiner.exe'), path.win32);
|
||||
assert.equal(result, appExe);
|
||||
},
|
||||
);
|
||||
},
|
||||
);
|
||||
withExistsAndStatSyncStubs({ existingPaths: [appExe], directoryPaths: [installDir] }, () => {
|
||||
withAccessSyncStub(
|
||||
(filePath) => filePath === appExe,
|
||||
() => {
|
||||
const result = findAppBinary(
|
||||
path.win32.join(baseDir, 'launcher', 'SubMiner.exe'),
|
||||
path.win32,
|
||||
);
|
||||
assert.equal(result, appExe);
|
||||
},
|
||||
);
|
||||
});
|
||||
});
|
||||
} finally {
|
||||
os.homedir = originalHomedir;
|
||||
|
||||
@@ -264,10 +264,7 @@ function getLinuxDesktopEnv(env: NodeJS.ProcessEnv): LinuxDesktopEnv {
|
||||
};
|
||||
}
|
||||
|
||||
function shouldForceX11MpvBackend(
|
||||
args: Pick<Args, 'backend'>,
|
||||
env: NodeJS.ProcessEnv,
|
||||
): boolean {
|
||||
function shouldForceX11MpvBackend(args: Pick<Args, 'backend'>, env: NodeJS.ProcessEnv): boolean {
|
||||
if (process.platform !== 'linux' || !env.DISPLAY?.trim()) {
|
||||
return false;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user