Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixes tests remaining from bibtexkey to citationkey rebranding #6918

Merged
merged 1 commit into from
Sep 18, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 12 additions & 12 deletions src/main/java/org/jabref/logic/help/HelpFile.java
Original file line number Diff line number Diff line change
Expand Up @@ -23,23 +23,23 @@ public enum HelpFile {
AUTOSAVE("general/autosave"),
// The help page covers both OO and LO.
OPENOFFICE_LIBREOFFICE("import-export/openofficeintegration"),
FETCHER_ACM("import-using-online-bibliographic-database/acmportal"),
FETCHER_ADS("import-using-online-bibliographic-database/ads"),
FETCHER_ACM("collect/import-using-online-bibliographic-database#acmportal"),
FETCHER_ADS("collect/import-using-online-bibliographic-database#ads"),
FETCHER_BIBSONOMY_SCRAPER(""),
FETCHER_CITESEERX("import-using-online-bibliographic-database/citeseer"),
FETCHER_DBLP("import-using-online-bibliographic-database/dblp"),
FETCHER_CITESEERX("collect/import-using-online-bibliographic-database#citeseer"),
FETCHER_DBLP("collect/import-using-online-bibliographic-database#dblp"),
FETCHER_DIVA("collect/add-entry-using-an-id"),
FETCHER_DOAJ("import-using-online-bibliographic-database/doaj"),
FETCHER_DOAJ("collect/import-using-online-bibliographic-database#doaj"),
FETCHER_DOI("collect/add-entry-using-an-id"),
FETCHER_GOOGLE_SCHOLAR("import-using-online-bibliographic-database/googlescholar"),
FETCHER_GVK("import-using-online-bibliographic-database/gvk"),
FETCHER_IEEEXPLORE("import-using-online-bibliographic-database/ieeexplore"),
FETCHER_INSPIRE("import-using-online-bibliographic-database/inspire"),
FETCHER_GOOGLE_SCHOLAR("collect/import-using-online-bibliographic-database#googlescholar"),
FETCHER_GVK("collect/import-using-online-bibliographic-database#gvk"),
FETCHER_IEEEXPLORE("collect/import-using-online-bibliographic-database#ieeexplore"),
FETCHER_INSPIRE("collect/import-using-online-bibliographic-database#inspire"),
FETCHER_ISBN("collect/add-entry-using-an-id"),
FETCHER_MEDLINE("import-using-online-bibliographic-database/medline"),
FETCHER_OAI2_ARXIV("import-using-online-bibliographic-database/arxiv"),
FETCHER_MEDLINE("collect/import-using-online-bibliographic-database#medline"),
FETCHER_OAI2_ARXIV("collect/import-using-online-bibliographic-database#arxiv"),
FETCHER_RFC("collect/add-entry-using-an-id"),
FETCHER_SPRINGER("import-using-online-bibliographic-database/springer"),
FETCHER_SPRINGER("collect/import-using-online-bibliographic-database#springer"),
FETCHER_TITLE("collect/add-entry-using-an-id"),
FETCHER_SCIENCEDIRECT(""),
DATABASE_PROPERTIES("setup/databaseproperties"),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -304,13 +304,18 @@ private static void migrateTypedKeyPrefs(JabRefPreferences prefs, Preferences ol

static void upgradePreviewStyleFromReviewToComment(JabRefPreferences prefs) {
String currentPreviewStyle = prefs.getPreviewStyle();
String migratedStyle = currentPreviewStyle.replace("\\begin{review}<BR><BR><b>Review: </b> \\format[HTMLChars]{\\review} \\end{review}", "\\begin{comment}<BR><BR><b>Comment: </b> \\format[HTMLChars]{\\comment} \\end{comment}");
String migratedStyle = currentPreviewStyle.replace("\\begin{review}<BR><BR><b>Review: </b> \\format[HTMLChars]{\\review} \\end{review}", "\\begin{comment}<BR><BR><b>Comment: </b> \\format[HTMLChars]{\\comment} \\end{comment}")
.replace("<b><i>\\bibtextype</i><a name=\"\\bibtexkey\">\\begin{bibtexkey} (\\bibtexkey)</a>", "<b><i>\\bibtextype</i><a name=\"\\citationkey\">\\begin{citationkey} (\\citationkey)</a>")
.replace("\\end{bibtexkey}</b><br>__NEWLINE__", "\\end{citationkey}</b><br>__NEWLINE__");
prefs.setPreviewStyle(migratedStyle);
}

static void upgradePreviewStyleAllowMarkdown(JabRefPreferences prefs) {
String currentPreviewStyle = prefs.getPreviewStyle();
String migratedStyle = currentPreviewStyle.replace("\\format[HTMLChars]{\\comment}", "\\format[Markdown,HTMLChars]{\\comment}");
String migratedStyle = currentPreviewStyle.replace("\\format[HTMLChars]{\\comment}", "\\format[Markdown,HTMLChars]{\\comment}")
.replace("<b><i>\\bibtextype</i><a name=\"\\bibtexkey\">\\begin{bibtexkey} (\\bibtexkey)</a>", "<b><i>\\bibtextype</i><a name=\"\\citationkey\">\\begin{citationkey} (\\citationkey)</a>")
.replace("\\end{bibtexkey}</b><br>__NEWLINE__", "\\end{citationkey}</b><br>__NEWLINE__");

prefs.setPreviewStyle(migratedStyle);
}

Expand Down