fix: rework logic for finding obsidian
Some checks failed
Playwright Tests / test (push) Failing after 2m0s

This commit is contained in:
☙◦ The Tablet ❀ GamerGirlandCo ◦❧ 2026-01-03 14:52:30 -05:00
parent a2bf146f99
commit ee6ee57d12
Signed by: tablet
GPG Key ID: 924A5F6AF051E87C

View File

@ -13,6 +13,9 @@ export interface ObsidianTestingConfig {
export function getExe(obsidianPath?: string): string {
checkToy();
if (obsidianPath) {
return path.join(obsidianPath, "Resources", "app.asar");
}
if (process.platform == "win32") {
const p = path.join(
process.env.LOCALAPPDATA!,
@ -22,13 +25,7 @@ export function getExe(obsidianPath?: string): string {
);
if (existsSync(p)) {
return p;
}
if (obsidianPath) {
const p = path.join(obsidianPath, "Resources", "app.asar");
if (existsSync(p)) {
return p;
}
}
}
}
const possibleDirs = [