|
20 | 20 | import org.jabref.model.metadata.SelfContainedSaveOrder; |
21 | 21 |
|
22 | 22 | import org.jspecify.annotations.NonNull; |
23 | | -import org.slf4j.Logger; |
24 | | -import org.slf4j.LoggerFactory; |
25 | 23 |
|
26 | 24 | /** |
27 | 25 | * A custom exporter to write multiple bib entries as AcademicPages Markdown format. |
28 | 26 | */ |
29 | 27 | public class AcademicPagesExporter extends Exporter { |
30 | | - private static final String BLANK_LINE_PATTERN = "\\r\\n|\\n"; |
31 | | - private static final String LAYOUT_PREFIX = "/resource/layout/"; |
32 | | - private static final String LAYOUT_EXTENSION = ".layout"; |
33 | | - private static final String FORMATTERS_EXTENSION = ".formatters"; |
34 | | - private static final String BEGIN_INFIX = ".begin"; |
35 | | - private static final String END_INFIX = ".end"; |
36 | | - |
37 | | - private static final Logger LOGGER = LoggerFactory.getLogger(AcademicPagesExporter.class); |
38 | 28 |
|
39 | 29 | private final String layoutFileFileName; |
40 | 30 | private final String directory; |
41 | 31 | private final LayoutFormatterPreferences layoutPreferences; |
42 | 32 | private final SelfContainedSaveOrder saveOrder; |
43 | | - private boolean customExport; |
44 | | - private List<BibEntry> entries; |
45 | 33 | private TemplateExporter academicPagesTemplate; |
46 | 34 |
|
47 | 35 | /** |
@@ -107,7 +95,7 @@ public void export(@NonNull final BibDatabaseContext databaseContext, |
107 | 95 |
|
108 | 96 | private static @NonNull Path getPath(BibEntry entry, Path exportDirectory) { |
109 | 97 | Replace replaceFormatter = new Replace(); |
110 | | - replaceFormatter.setArgument(" ,-"); // The replaceFormatter expects a "-" instead of " " hence the strange argument. |
| 98 | + replaceFormatter.setArgument(" ,-"); // expects an expression that has the character to remove and the replacement character separated by a comma. |
111 | 99 | RemoveLatexCommandsFormatter commandsFormatter = new RemoveLatexCommandsFormatter(); |
112 | 100 | HTMLChars htmlFormatter = new HTMLChars(); |
113 | 101 | String title = entry.getTitle().get(); |
|
0 commit comments