Skip to content

Commit

Permalink
Do not run auto-configuration unless necessary.
Browse files Browse the repository at this point in the history
  • Loading branch information
szhorvat committed Nov 18, 2015
1 parent 28a53b2 commit 7e3937a
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions MaTeX.m
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@
"pdfLaTeX" -> winFindPL[]
|>;

$defaultConfig =
$defaultConfig :=
Switch[$OperatingSystem,
"MacOSX", Join[$defaultConfigBase, $defaultConfigOSX],
"Unix", Join[$defaultConfigBase, $defaultConfigLinux],
Expand All @@ -101,7 +101,9 @@
$config = <||>
];

$config = Join[$defaultConfig, $config]
If[Not@SubsetQ[Keys[$config], Keys[$defaultConfigBase]],
$config = Join[$defaultConfig, $config]
];
Export[$configFile, $config, "Package"]

(* True if file exists and is not a directory *)
Expand Down

0 comments on commit 7e3937a

Please sign in to comment.