Skip to content

Commit

Permalink
fix: use zotero cli args to set dataDir
Browse files Browse the repository at this point in the history
fixes: #73
  • Loading branch information
northword committed Dec 18, 2024
1 parent 54ad99e commit 15a807e
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions src/utils/zotero-runner.ts
Original file line number Diff line number Diff line change
Expand Up @@ -83,9 +83,6 @@ export class ZoteroRunner {
) {
return "";
}
if (line.includes("extensions.zotero.dataDir") && this.options.dataDir !== "") {
return `user_pref("extensions.zotero.dataDir", "${this.options.dataDir}");`;
}
return line;
});
}
Expand All @@ -103,7 +100,11 @@ export class ZoteroRunner {
// Build args
let args: string[] = ["--purgecaches", "no-remote"];
if (this.options.profilePath) {
args.push("-profile", this.options.profilePath);
args.push("-profile", resolve(this.options.profilePath));
}
if (this.options.dataDir) {
// '--dataDir' required absolute path
args.push("--dataDir", resolve(this.options.dataDir));
}
if (this.options.devtools) {
args.push("--jsdebugger");
Expand Down

0 comments on commit 15a807e

Please sign in to comment.